Gentoo Archives: gentoo-commits

From: "Tim Harder (radhermit)" <radhermit@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in media-sound/csound/files: csound-5.16.6-scons.patch
Date: Wed, 29 Feb 2012 00:54:23
Message-Id: 20120229005413.7CCB12004C@flycatcher.gentoo.org
1 radhermit 12/02/29 00:54:13
2
3 Modified: csound-5.16.6-scons.patch
4 Log:
5 Revbump to add luajit use flag to control using dev-lang/luajit instead of dev-lang/lua.
6
7 (Portage version: 2.2.0_alpha89/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.3 media-sound/csound/files/csound-5.16.6-scons.patch
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/csound/files/csound-5.16.6-scons.patch?rev=1.3&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/csound/files/csound-5.16.6-scons.patch?rev=1.3&content-type=text/plain
14 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-sound/csound/files/csound-5.16.6-scons.patch?r1=1.2&r2=1.3
15
16 Index: csound-5.16.6-scons.patch
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/media-sound/csound/files/csound-5.16.6-scons.patch,v
19 retrieving revision 1.2
20 retrieving revision 1.3
21 diff -u -r1.2 -r1.3
22 --- csound-5.16.6-scons.patch 28 Feb 2012 21:19:38 -0000 1.2
23 +++ csound-5.16.6-scons.patch 29 Feb 2012 00:54:13 -0000 1.3
24 @@ -10,7 +10,17 @@
25 commandOptions.Add('useALSA',
26 'Set to 1 to use ALSA for real-time audio and MIDI input and output.',
27 '1')
28 -@@ -180,6 +183,15 @@
29 +@@ -101,6 +104,9 @@
30 + commandOptions.Add('noFLTKThreads',
31 + 'Set to 1 to disable use of a separate thread for FLTK widgets.',
32 + '1')
33 ++commandOptions.Add('useLuaJIT',
34 ++ 'Set to 1 to use the Just-In-Time Compiler for Lua',
35 ++ '1')
36 + commandOptions.Add('pythonVersion',
37 + 'Set to the Python version to be used.',
38 + '%d.%d' % (int(sys.hexversion) >> 24, (int(sys.hexversion) >> 16) & 255))
39 +@@ -180,6 +186,15 @@
40 commandOptions.Add('dynamicCsoundLibrary',
41 'Build dynamic Csound library instead of libcsound.a',
42 '0')
43 @@ -26,7 +36,7 @@
44 commandOptions.Add('buildStkOpcodes',
45 "Build opcodes encapsulating Perry Cook's Synthesis Toolkit in C++ instruments and effects",
46 '0')
47 -@@ -352,6 +364,7 @@
48 +@@ -352,6 +367,7 @@
49 fileOptions.Add('customCXXFLAGS')
50 fileOptions.Add('customLIBS')
51 fileOptions.Add('customLIBPATH')
52 @@ -34,7 +44,7 @@
53 fileOptions.Add('customSHLINKFLAGS')
54 fileOptions.Add('customSWIGFLAGS')
55 fileOptions.Update(commonEnvironment)
56 -@@ -366,6 +379,8 @@
57 +@@ -366,6 +382,8 @@
58 commonEnvironment.Prepend(LIBS = customLIBS)
59 customLIBPATH = commonEnvironment['customLIBPATH']
60 commonEnvironment.Prepend(LIBPATH = customLIBPATH)
61 @@ -43,7 +53,7 @@
62 customSHLINKFLAGS = commonEnvironment['customSHLINKFLAGS']
63 commonEnvironment.Prepend(SHLINKFLAGS = customSHLINKFLAGS)
64 customSWIGFLAGS = commonEnvironment['customSWIGFLAGS']
65 -@@ -469,14 +484,6 @@
66 +@@ -469,14 +487,6 @@
67 if commonEnvironment['buildRelease'] == '0':
68 commonEnvironment.Prepend(CPPFLAGS = ['-DBETA'])
69
70 @@ -58,18 +68,18 @@
71 if commonEnvironment['Word64'] == '1':
72 if compilerSun():
73 commonEnvironment.Append(CCFLAGS = ['-xcode=pic32'])
74 -@@ -494,10 +501,7 @@
75 +@@ -494,10 +504,7 @@
76 if getPlatform() == 'linux':
77 commonEnvironment.Append(CCFLAGS = ["-DLINUX"])
78 commonEnvironment.Append(CPPFLAGS = ['-DHAVE_SOCKETS'])
79 - commonEnvironment.Append(CPPPATH = ['/usr/local/include'])
80 - commonEnvironment.Append(CPPPATH = ['/usr/include'])
81 - commonEnvironment.Append(CPPPATH = ['/usr/include'])
82 + commonEnvironment.Append(CPPPATH = ['/usr/include'])
83 - commonEnvironment.Append(CPPPATH = ['/usr/X11R6/include'])
84 commonEnvironment.Append(CCFLAGS = ["-DPIPES"])
85 commonEnvironment.Append(LINKFLAGS = ['-Wl,-Bdynamic'])
86 elif getPlatform() == 'sunos':
87 -@@ -559,18 +563,17 @@
88 +@@ -559,18 +566,17 @@
89
90 if getPlatform() == 'linux':
91 path1 = '/usr/include/python%s' % commonEnvironment['pythonVersion']
92 @@ -91,7 +101,7 @@
93 pythonLibs = ['python%s' % commonEnvironment['pythonVersion']]
94 elif getPlatform() == 'sunos':
95 path1 = '/usr/include/python%s' % commonEnvironment['pythonVersion']
96 -@@ -777,6 +780,7 @@
97 +@@ -777,6 +783,7 @@
98 zlibhfound = configure.CheckHeader("zlib.h", language = "C")
99 midiPluginSdkFound = configure.CheckHeader("funknown.h", language = "C++")
100 luaFound = configure.CheckHeader("lua.h", language = "C")
101 @@ -99,16 +109,46 @@
102 #print 'LUA: %s' % (['no', 'yes'][int(luaFound)])
103 swigFound = 'swig' in commonEnvironment['TOOLS']
104 print 'Checking for SWIG... %s' % (['no', 'yes'][int(swigFound)])
105 -@@ -1452,7 +1456,7 @@
106 +@@ -1452,24 +1459,30 @@
107 swigflags = csoundWrapperEnvironment['SWIGFLAGS']
108 print 'swigflags:', swigflags
109 luaWrapper = None
110 - if not (luaFound and commonEnvironment['buildLuaWrapper'] != '0'):
111 -+ if not (luajitFound and commonEnvironment['buildLuaWrapper'] != '0'):
112 ++ if not (luaFound or luajitFound and commonEnvironment['buildLuaWrapper'] != '0'):
113 print 'CONFIGURATION DECISION: Not building Lua wrapper to Csound C++ interface library.'
114 else:
115 print 'CONFIGURATION DECISION: Building Lua wrapper to Csound C++ interface library.'
116 -@@ -1510,6 +1514,9 @@
117 + luaWrapperEnvironment = csoundWrapperEnvironment.Clone()
118 + if getPlatform() != 'win32':
119 +- csoundWrapperEnvironment.Append(CPPPATH=['/usr/include/lua5.1'])
120 ++ if luajitFound and commonEnvironment['useLuaJIT'] == '1':
121 ++ csoundWrapperEnvironment.Append(CPPPATH=['/usr/include/luajit-2.0'])
122 ++ else:
123 ++ csoundWrapperEnvironment.Append(CPPPATH=['/usr/include/lua5.1'])
124 + if getPlatform() == 'win32':
125 + csoundLuaInterface = luaWrapperEnvironment.SharedObject(
126 + 'interfaces/lua_interface.i',
127 + SWIGFLAGS = [swigflags, '-lua', '-module', 'luaCsnd', '-lua51', '-outdir', '.'])
128 + luaWrapperEnvironment.Prepend(LIBS = ['csnd','luaj51'])
129 +- else:
130 +- csoundLuaInterface = luaWrapperEnvironment.SharedObject(
131 +- 'interfaces/lua_interface.i',
132 +- SWIGFLAGS = [swigflags, '-lua', '-module', 'luaCsnd', '-outdir', '.'])
133 +- luaWrapperEnvironment.Prepend(LIBS = ['csnd','luajit-5.1'])
134 +- luaWrapper = makeLuaModule(luaWrapperEnvironment, 'luaCsnd', [csoundLuaInterface])
135 ++ else:
136 ++ csoundLuaInterface = luaWrapperEnvironment.SharedObject(
137 ++ 'interfaces/lua_interface.i',
138 ++ SWIGFLAGS = [swigflags, '-lua', '-module', 'luaCsnd', '-outdir', '.'])
139 ++ if luajitFound and commonEnvironment['useLuaJIT'] == '1':
140 ++ luaWrapperEnvironment.Prepend(LIBS = ['csnd','luajit-5.1'])
141 ++ else:
142 ++ luaWrapperEnvironment.Prepend(LIBS = ['csnd','lua'])
143 ++ luaWrapper = makeLuaModule(luaWrapperEnvironment, 'luaCsnd', [csoundLuaInterface])
144 + Depends(luaWrapper, csoundLuaInterface)
145 +
146 + if not (javaFound and commonEnvironment['buildJavaWrapper'] != '0'):
147 +@@ -1510,6 +1523,9 @@
148 javaWrapper = javaWrapperEnvironment.Program(
149 'lib_jcsound.jnilib', javaWrapperSources)
150 else:
151 @@ -118,7 +158,7 @@
152 javaWrapper = javaWrapperEnvironment.SharedLibrary(
153 '_jcsound', javaWrapperSources)
154 #Depends(javaWrapper, csoundLibrary)
155 -@@ -1759,9 +1766,12 @@
156 +@@ -1759,9 +1775,12 @@
157 jpluginEnvironment.Append(LINKFLAGS = ['-framework', 'Jackmp'])
158 makePlugin(jpluginEnvironment, 'jackTransport', 'Opcodes/jackTransport.c')
159 makePlugin(jpluginEnvironment, 'jacko', 'Opcodes/jacko.cpp')
160 @@ -133,7 +173,7 @@
161 makePlugin(pluginEnvironment, 'linear_algebra', 'Opcodes/linear_algebra.cpp')
162 print 'CONFIGURATION DECISION: Building linear algebra opcodes.'
163 else:
164 -@@ -1893,11 +1903,13 @@
165 +@@ -1893,11 +1912,13 @@
166 alsaEnvironment.Append(LIBS = ['asound', 'pthread'])
167 makePlugin(alsaEnvironment, 'rtalsa', ['InOut/rtalsa.c'])
168
169 @@ -148,7 +188,7 @@
170
171 if getPlatform() == 'win32':
172 winmmEnvironment = pluginEnvironment.Clone()
173 -@@ -1963,9 +1975,7 @@
174 +@@ -1963,9 +1984,7 @@
175
176 # FLUIDSYNTH OPCODES
177
178 @@ -159,7 +199,7 @@
179 print "CONFIGURATION DECISION: Building fluid opcodes."
180 fluidEnvironment = pluginEnvironment.Clone()
181 if getPlatform() == 'win32':
182 -@@ -1981,6 +1991,8 @@
183 +@@ -1981,6 +2000,8 @@
184 fluidEnvironment.Append(LIBS = ['pthread'])
185 makePlugin(fluidEnvironment, 'fluidOpcodes',
186 ['Opcodes/fluidOpcodes/fluidOpcodes.cpp'])
187 @@ -168,7 +208,7 @@
188
189 # VST HOST OPCODES
190
191 -@@ -2174,7 +2186,7 @@
192 +@@ -2174,7 +2195,7 @@
193 if getPlatform() == 'win32' and pythonLibs[0] < 'python24':
194 Depends(pythonOpcodes, pythonImportLibrary)
195
196 @@ -177,25 +217,59 @@
197
198 if not (commonEnvironment['buildLuaOpcodes'] != '0'):
199 print "CONFIGURATION DECISION: Not building Lua opcodes."
200 -@@ -2183,10 +2195,10 @@
201 +@@ -2183,10 +2204,13 @@
202 luaEnvironment = pluginEnvironment.Clone()
203
204 if getPlatform() == 'linux':
205 - if(luaFound == 1):
206 -+ if(luajitFound == 1):
207 ++ if(luajitFound == 1 and commonEnvironment['useLuaJIT'] == '1'):
208 luaEnvironment.Append(LIBS = ['luajit-5.1'])
209 luaEnvironment.Append(LIBS = ['util', 'dl', 'm'])
210 - luaEnvironment.Append(CPPPATH = '/usr/local/include/luajit-2.0')
211 + luaEnvironment.Append(CPPPATH = '/usr/include/luajit-2.0')
212 ++ elif(luaFound == 1):
213 ++ luaEnvironment.Append(LIBS = ['lua'])
214 ++ luaEnvironment.Append(LIBS = ['util', 'dl', 'm'])
215 elif getPlatform() == 'win32':
216 if(luaFound == 1):
217 luaEnvironment.Append(LIBS = ['lua51'])
218 -@@ -2538,7 +2550,7 @@
219 +@@ -2538,21 +2562,24 @@
220 Depends(csoundAcPythonModule, pythonWrapper)
221 Depends(csoundAcPythonModule, csoundac)
222 Depends(csoundAcPythonModule, csnd)
223 - if luaFound and commonEnvironment['buildLuaWrapper'] != '0':
224 -+ if luajitFound and commonEnvironment['buildLuaWrapper'] != '0':
225 - luaCsoundACWrapperEnvironment = acWrapperEnvironment.Clone()
226 - if getPlatform() == 'win32':
227 - luaCsoundACWrapperEnvironment.Prepend(LIBS = Split('luaCsnd lua51 CsoundAC csnd fltk_images'))
228 +- luaCsoundACWrapperEnvironment = acWrapperEnvironment.Clone()
229 +- if getPlatform() == 'win32':
230 +- luaCsoundACWrapperEnvironment.Prepend(LIBS = Split('luaCsnd lua51 CsoundAC csnd fltk_images'))
231 +- else:
232 +- luaCsoundACWrapperEnvironment.Prepend(LIBS = [luaWrapper])
233 +- luaCsoundACWrapperEnvironment.Prepend(LIBS = Split('luajit-5.1 CsoundAC csnd fltk_images'))
234 +- luaCsoundACWrapper = luaCsoundACWrapperEnvironment.SharedObject(
235 +- 'frontends/CsoundAC/luaCsoundAC.i', SWIGFLAGS = [swigflags, Split('-lua ')])
236 +- luaCsoundACWrapperEnvironment.Clean('.', 'frontends/CsoundAC/luaCsoundAC_wrap.h')
237 +- CsoundAclModule = makeLuaModule(luaCsoundACWrapperEnvironment, 'luaCsoundAC', [luaCsoundACWrapper])
238 +- Depends(CsoundAclModule, luaCsoundACWrapper)
239 +- Depends(CsoundAclModule, luaWrapper)
240 +- Depends(CsoundAclModule, csoundac)
241 +- Depends(CsoundAclModule, csnd)
242 ++ if (luajitFound or luaFound) and commonEnvironment['buildLuaWrapper'] != '0':
243 ++ luaCsoundACWrapperEnvironment = acWrapperEnvironment.Clone()
244 ++ if getPlatform() == 'win32':
245 ++ luaCsoundACWrapperEnvironment.Prepend(LIBS = Split('luaCsnd lua51 CsoundAC csnd fltk_images'))
246 ++ else:
247 ++ luaCsoundACWrapperEnvironment.Prepend(LIBS = [luaWrapper])
248 ++ if commonEnvironment['useLuaJIT'] == '1':
249 ++ luaCsoundACWrapperEnvironment.Prepend(LIBS = Split('luajit-5.1 CsoundAC csnd fltk_images'))
250 ++ else:
251 ++ luaCsoundACWrapperEnvironment.Prepend(LIBS = Split('lua CsoundAC csnd fltk_images'))
252 ++ luaCsoundACWrapper = luaCsoundACWrapperEnvironment.SharedObject(
253 ++ 'frontends/CsoundAC/luaCsoundAC.i', SWIGFLAGS = [swigflags, Split('-lua ')])
254 ++ luaCsoundACWrapperEnvironment.Clean('.', 'frontends/CsoundAC/luaCsoundAC_wrap.h')
255 ++ CsoundAclModule = makeLuaModule(luaCsoundACWrapperEnvironment, 'luaCsoundAC', [luaCsoundACWrapper])
256 ++ Depends(CsoundAclModule, luaCsoundACWrapper)
257 ++ Depends(CsoundAclModule, luaWrapper)
258 ++ Depends(CsoundAclModule, csoundac)
259 ++ Depends(CsoundAclModule, csnd)
260 +
261 +
262 + # Build CsoundVST