Imported Upstream version 3.2.2
[debian/gnuradio] / gnuradio-core / src / lib / swig / Makefile.swig.gen
1 # -*- Makefile -*-
2 #
3 # Copyright 2009 Free Software Foundation, Inc.
4
5 # This file is part of GNU Radio
6
7 # GNU Radio is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 3, or (at your option)
10 # any later version.
11
12 # GNU Radio is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 # GNU General Public License for more details.
16
17 # You should have received a copy of the GNU General Public License
18 # along with GNU Radio; see the file COPYING.  If not, write to
19 # the Free Software Foundation, Inc., 51 Franklin Street,
20 # Boston, MA 02110-1301, USA.
21
22
23 # Makefile.swig.gen for gnuradio_swig_py_runtime.i
24
25 ## Default install locations for these files:
26 ##
27 ## Default location for the Python directory is:
28 ##  ${prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_runtime
29 ## Default location for the Python exec directory is:
30 ##  ${exec_prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_runtime
31 ##
32 ## The following can be overloaded to change the install location, but
33 ## this has to be done in the including Makefile.am -before-
34 ## Makefile.swig is included.
35
36 gnuradio_swig_py_runtime_pythondir_category ?= gnuradio/gnuradio_swig_py_runtime
37 gnuradio_swig_py_runtime_pylibdir_category ?= $(gnuradio_swig_py_runtime_pythondir_category)
38 gnuradio_swig_py_runtime_pythondir = $(pythondir)/$(gnuradio_swig_py_runtime_pythondir_category)
39 gnuradio_swig_py_runtime_pylibdir = $(pyexecdir)/$(gnuradio_swig_py_runtime_pylibdir_category)
40
41 ## SWIG headers are always installed into the same directory.
42
43 gnuradio_swig_py_runtime_swigincludedir = $(swigincludedir)
44
45 ## This is a template file for a "generated" Makefile addition (in
46 ## this case, "Makefile.swig.gen").  By including the top-level
47 ## Makefile.swig, this file will be used to generate the SWIG
48 ## dependencies.  Assign the variable TOP_SWIG_FILES to be the list of
49 ## SWIG .i files to generated wrappings for; there can be more than 1
50 ## so long as the names are unique (no sorting is done on the
51 ## TOP_SWIG_FILES list). This file explicitly assumes that a SWIG .i
52 ## file will generate .cc, .py, and possibly .h files -- meaning that
53 ## all of these files will have the same base name (that provided for
54 ## the SWIG .i file).
55 ##
56 ## This code is setup to ensure parallel MAKE ("-j" or "-jN") does the
57 ## right thing.  For more info, see <
58 ## http://sources.redhat.com/automake/automake.html#Multiple-Outputs >
59
60 ## Stamps used to ensure parallel make does the right thing.  These
61 ## are removed by "make clean", but otherwise unused except during the
62 ## parallel built.  These will not be included in a tarball, because
63 ## the SWIG-generated files will be removed from the distribution.
64
65 STAMPS += $(DEPDIR)/gnuradio_swig_py_runtime-generate-*
66
67 ## Other cleaned files: dependency files generated by SWIG or this Makefile
68
69 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
70
71 ## Add the .py and .cc files to the list of SWIG built sources.  The
72 ## .h file is sometimes built, but not always ... so that one has to
73 ## be added manually by the including Makefile.am .
74
75 swig_built_sources += gnuradio_swig_py_runtime.py gnuradio_swig_py_runtime.cc
76
77 ## Various SWIG variables.  These can be overloaded in the including
78 ## Makefile.am by setting the variable value there, then including
79 ## Makefile.swig .
80
81 gnuradio_swig_py_runtime_swiginclude_HEADERS =          \
82         gnuradio_swig_py_runtime.i                      \
83         $(gnuradio_swig_py_runtime_swiginclude_headers)
84
85 gnuradio_swig_py_runtime_pylib_LTLIBRARIES =            \
86         _gnuradio_swig_py_runtime.la
87
88 _gnuradio_swig_py_runtime_la_SOURCES =                  \
89         gnuradio_swig_py_runtime.cc                     \
90         $(gnuradio_swig_py_runtime_la_swig_sources)
91
92 _gnuradio_swig_py_runtime_la_LIBADD =                   \
93         $(STD_SWIG_LA_LIB_ADD)          \
94         $(gnuradio_swig_py_runtime_la_swig_libadd)
95
96 _gnuradio_swig_py_runtime_la_LDFLAGS =                  \
97         $(STD_SWIG_LA_LD_FLAGS)         \
98         $(gnuradio_swig_py_runtime_la_swig_ldflags)
99
100 _gnuradio_swig_py_runtime_la_CXXFLAGS =                 \
101         $(STD_SWIG_CXX_FLAGS)           \
102         $(gnuradio_swig_py_runtime_la_swig_cxxflags)
103
104 gnuradio_swig_py_runtime_python_PYTHON =                        \
105         gnuradio_swig_py_runtime.py                     \
106         $(gnuradio_swig_py_runtime_python)
107
108 ## Entry rule for running SWIG
109
110 gnuradio_swig_py_runtime.h gnuradio_swig_py_runtime.py gnuradio_swig_py_runtime.cc: gnuradio_swig_py_runtime.i
111 ## This rule will get called only when MAKE decides that one of the
112 ## targets needs to be created or re-created, because:
113 ##
114 ## * The .i file is newer than any or all of the generated files;
115 ##
116 ## * Any or all of the .cc, .h, or .py files does not exist and is
117 ##   needed (in the case this file is not needed, the rule for it is
118 ##   ignored); or
119 ##
120 ## * Some SWIG-based dependecy of the .cc file isn't met and hence the
121 ##   .cc file needs be be regenerated.  Explanation: Because MAKE
122 ##   knows how to handle dependencies for .cc files (regardless of
123 ##   their name or extension), then the .cc file is used as a target
124 ##   instead of the .i file -- but with the dependencies of the .i
125 ##   file.  It is this last reason why the line:
126 ##
127 ##      if test -f $@; then :; else
128 ##
129 ##   cannot be used in this case: If a .i file dependecy is not met,
130 ##   then the .cc file needs to be rebuilt.  But if the stamp is newer
131 ##   than the .cc file, and the .cc file exists, then in the original
132 ##   version (with the 'test' above) the internal MAKE call will not
133 ##   be issued and hence the .cc file will not be rebuilt.
134 ##
135 ## Once execution gets to here, it should always proceed no matter the
136 ## state of a stamp (as discussed in link above).  The
137 ## $(DEPDIR)/gnuradio_swig_py_runtime-generate stuff is used to allow for parallel
138 ## builds to "do the right thing".  The stamp has no relationship with
139 ## either the target files or dependency file; it is used solely for
140 ## the protection of multiple builds during a given call to MAKE.
141 ##
142 ## Catch signals SIGHUP (1), SIGINT (2), SIGPIPE (13), and SIGTERM
143 ## (15).  At a caught signal, the quoted command will be issued before
144 ## exiting.  In this case, remove any stamp, whether temporary of not.
145 ## The trap is valid until the process exits; the process includes all
146 ## commands appended via "\"s.
147 ##
148         trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_runtime-generate-*' 1 2 13 15; \
149 ##
150 ## Create a temporary directory, which acts as a lock.  The first
151 ## process to create the directory will succeed and issue the MAKE
152 ## command to do the actual work, while all subsequent processes will
153 ## fail -- leading them to wait for the first process to finish.
154 ##
155         if mkdir $(DEPDIR)/gnuradio_swig_py_runtime-generate-lock 2>/dev/null; then \
156 ##
157 ## This code is being executed by the first process to succeed in
158 ## creating the directory lock.
159 ##
160 ## Remove the stamp associated with this filename.
161 ##
162                 rm -f $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp; \
163 ##
164 ## Tell MAKE to run the rule for creating this stamp.
165 ##
166                 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp WHAT=$<; \
167 ##
168 ## Now that the .cc, .h, and .py files have been (re)created from the
169 ## .i file, future checking of this rule during the same MAKE
170 ## execution will come back that the rule doesn't need to be executed
171 ## because none of the conditions mentioned at the start of this rule
172 ## will be positive.  Remove the the directory lock, which frees up
173 ## any waiting process(es) to continue.
174 ##
175                 rmdir $(DEPDIR)/gnuradio_swig_py_runtime-generate-lock; \
176         else \
177 ##
178 ## This code is being executed by any follower processes while the
179 ## directory lock is in place.
180 ##
181 ## Wait until the first process is done, testing once per second.
182 ##
183                 while test -d $(DEPDIR)/gnuradio_swig_py_runtime-generate-lock; do \
184                         sleep 1; \
185                 done; \
186 ##
187 ## Succeed if and only if the first process succeeded; exit this
188 ## process returning the status of the generated stamp.
189 ##
190                 test -f $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp; \
191                 exit $$?; \
192         fi;
193
194 $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp:
195 ## This rule will be called only by the first process issuing the
196 ## above rule to succeed in creating the lock directory, after
197 ## removing the actual stamp file in order to guarantee that MAKE will
198 ## execute this rule.
199 ##
200 ## Call SWIG to generate the various output files; special
201 ## post-processing on 'mingw32' host OS for the dependency file.
202 ##
203         if $(SWIG) $(STD_SWIG_PYTHON_ARGS) $(gnuradio_swig_py_runtime_swig_args) \
204                 -MD -MF $(DEPDIR)/gnuradio_swig_py_runtime.Std \
205                 -module gnuradio_swig_py_runtime -o gnuradio_swig_py_runtime.cc $(WHAT); then \
206             if test $(host_os) = mingw32; then \
207                 $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.Sd; \
208                 $(SED) 's,\\\\,/,g' < $(DEPDIR)/gnuradio_swig_py_runtime.Std \
209                         > $(DEPDIR)/gnuradio_swig_py_runtime.Sd; \
210                 $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.Std; \
211                 $(MV) $(DEPDIR)/gnuradio_swig_py_runtime.Sd $(DEPDIR)/gnuradio_swig_py_runtime.Std; \
212             fi; \
213         else \
214             $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.S*; exit 1; \
215         fi;
216 ##
217 ## Mess with the SWIG output .Std dependency file, to create a
218 ## dependecy file valid for the input .i file: Basically, simulate the
219 ## dependency file created for libraries by GNU's libtool for C++,
220 ## where all of the dependencies for the target are first listed, then
221 ## each individual dependency is listed as a target with no further
222 ## dependencies.
223 ##
224 ## (1) remove the current dependency file
225 ##
226         $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.d
227 ##
228 ## (2) Copy the whole SWIG file:
229 ##
230         cp $(DEPDIR)/gnuradio_swig_py_runtime.Std $(DEPDIR)/gnuradio_swig_py_runtime.d
231 ##
232 ## (3) all a carriage return to the end of the dependency file.
233 ##
234         echo "" >> $(DEPDIR)/gnuradio_swig_py_runtime.d
235 ##
236 ## (4) from the SWIG file, remove the first line (the target); remove
237 ##     trailing " \" and " " from each line.  Append ":" to each line,
238 ##     followed by 2 carriage returns, then append this to the end of
239 ##     the dependency file.
240 ##
241         $(SED) -e '1d;s, \\,,g;s, ,,g' < $(DEPDIR)/gnuradio_swig_py_runtime.Std | \
242                 awk '{ printf "%s:\n\n", $$0 }' >> $(DEPDIR)/gnuradio_swig_py_runtime.d
243 ##
244 ## (5) remove the SWIG-generated file
245 ##
246         $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.Std
247 ##
248 ## Create the stamp for this filename generation, to signal success in
249 ## executing this rule; allows other threads waiting on this process
250 ## to continue.
251 ##
252         touch $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp
253
254 # KLUDGE: Force runtime include of a SWIG dependency file.  This is
255 # not guaranteed to be portable, but will probably work.  If it works,
256 # we have accurate dependencies for our swig stuff, which is good.
257
258 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_runtime.d@am__quote@
259
260 # -*- Makefile -*-
261 #
262 # Copyright 2009 Free Software Foundation, Inc.
263
264 # This file is part of GNU Radio
265
266 # GNU Radio is free software; you can redistribute it and/or modify
267 # it under the terms of the GNU General Public License as published by
268 # the Free Software Foundation; either version 3, or (at your option)
269 # any later version.
270
271 # GNU Radio is distributed in the hope that it will be useful,
272 # but WITHOUT ANY WARRANTY; without even the implied warranty of
273 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
274 # GNU General Public License for more details.
275
276 # You should have received a copy of the GNU General Public License
277 # along with GNU Radio; see the file COPYING.  If not, write to
278 # the Free Software Foundation, Inc., 51 Franklin Street,
279 # Boston, MA 02110-1301, USA.
280
281
282 # Makefile.swig.gen for gnuradio_swig_py_general.i
283
284 ## Default install locations for these files:
285 ##
286 ## Default location for the Python directory is:
287 ##  ${prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_general
288 ## Default location for the Python exec directory is:
289 ##  ${exec_prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_general
290 ##
291 ## The following can be overloaded to change the install location, but
292 ## this has to be done in the including Makefile.am -before-
293 ## Makefile.swig is included.
294
295 gnuradio_swig_py_general_pythondir_category ?= gnuradio/gnuradio_swig_py_general
296 gnuradio_swig_py_general_pylibdir_category ?= $(gnuradio_swig_py_general_pythondir_category)
297 gnuradio_swig_py_general_pythondir = $(pythondir)/$(gnuradio_swig_py_general_pythondir_category)
298 gnuradio_swig_py_general_pylibdir = $(pyexecdir)/$(gnuradio_swig_py_general_pylibdir_category)
299
300 ## SWIG headers are always installed into the same directory.
301
302 gnuradio_swig_py_general_swigincludedir = $(swigincludedir)
303
304 ## This is a template file for a "generated" Makefile addition (in
305 ## this case, "Makefile.swig.gen").  By including the top-level
306 ## Makefile.swig, this file will be used to generate the SWIG
307 ## dependencies.  Assign the variable TOP_SWIG_FILES to be the list of
308 ## SWIG .i files to generated wrappings for; there can be more than 1
309 ## so long as the names are unique (no sorting is done on the
310 ## TOP_SWIG_FILES list). This file explicitly assumes that a SWIG .i
311 ## file will generate .cc, .py, and possibly .h files -- meaning that
312 ## all of these files will have the same base name (that provided for
313 ## the SWIG .i file).
314 ##
315 ## This code is setup to ensure parallel MAKE ("-j" or "-jN") does the
316 ## right thing.  For more info, see <
317 ## http://sources.redhat.com/automake/automake.html#Multiple-Outputs >
318
319 ## Stamps used to ensure parallel make does the right thing.  These
320 ## are removed by "make clean", but otherwise unused except during the
321 ## parallel built.  These will not be included in a tarball, because
322 ## the SWIG-generated files will be removed from the distribution.
323
324 STAMPS += $(DEPDIR)/gnuradio_swig_py_general-generate-*
325
326 ## Other cleaned files: dependency files generated by SWIG or this Makefile
327
328 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
329
330 ## Add the .py and .cc files to the list of SWIG built sources.  The
331 ## .h file is sometimes built, but not always ... so that one has to
332 ## be added manually by the including Makefile.am .
333
334 swig_built_sources += gnuradio_swig_py_general.py gnuradio_swig_py_general.cc
335
336 ## Various SWIG variables.  These can be overloaded in the including
337 ## Makefile.am by setting the variable value there, then including
338 ## Makefile.swig .
339
340 gnuradio_swig_py_general_swiginclude_HEADERS =          \
341         gnuradio_swig_py_general.i                      \
342         $(gnuradio_swig_py_general_swiginclude_headers)
343
344 gnuradio_swig_py_general_pylib_LTLIBRARIES =            \
345         _gnuradio_swig_py_general.la
346
347 _gnuradio_swig_py_general_la_SOURCES =                  \
348         gnuradio_swig_py_general.cc                     \
349         $(gnuradio_swig_py_general_la_swig_sources)
350
351 _gnuradio_swig_py_general_la_LIBADD =                   \
352         $(STD_SWIG_LA_LIB_ADD)          \
353         $(gnuradio_swig_py_general_la_swig_libadd)
354
355 _gnuradio_swig_py_general_la_LDFLAGS =                  \
356         $(STD_SWIG_LA_LD_FLAGS)         \
357         $(gnuradio_swig_py_general_la_swig_ldflags)
358
359 _gnuradio_swig_py_general_la_CXXFLAGS =                 \
360         $(STD_SWIG_CXX_FLAGS)           \
361         $(gnuradio_swig_py_general_la_swig_cxxflags)
362
363 gnuradio_swig_py_general_python_PYTHON =                        \
364         gnuradio_swig_py_general.py                     \
365         $(gnuradio_swig_py_general_python)
366
367 ## Entry rule for running SWIG
368
369 gnuradio_swig_py_general.h gnuradio_swig_py_general.py gnuradio_swig_py_general.cc: gnuradio_swig_py_general.i
370 ## This rule will get called only when MAKE decides that one of the
371 ## targets needs to be created or re-created, because:
372 ##
373 ## * The .i file is newer than any or all of the generated files;
374 ##
375 ## * Any or all of the .cc, .h, or .py files does not exist and is
376 ##   needed (in the case this file is not needed, the rule for it is
377 ##   ignored); or
378 ##
379 ## * Some SWIG-based dependecy of the .cc file isn't met and hence the
380 ##   .cc file needs be be regenerated.  Explanation: Because MAKE
381 ##   knows how to handle dependencies for .cc files (regardless of
382 ##   their name or extension), then the .cc file is used as a target
383 ##   instead of the .i file -- but with the dependencies of the .i
384 ##   file.  It is this last reason why the line:
385 ##
386 ##      if test -f $@; then :; else
387 ##
388 ##   cannot be used in this case: If a .i file dependecy is not met,
389 ##   then the .cc file needs to be rebuilt.  But if the stamp is newer
390 ##   than the .cc file, and the .cc file exists, then in the original
391 ##   version (with the 'test' above) the internal MAKE call will not
392 ##   be issued and hence the .cc file will not be rebuilt.
393 ##
394 ## Once execution gets to here, it should always proceed no matter the
395 ## state of a stamp (as discussed in link above).  The
396 ## $(DEPDIR)/gnuradio_swig_py_general-generate stuff is used to allow for parallel
397 ## builds to "do the right thing".  The stamp has no relationship with
398 ## either the target files or dependency file; it is used solely for
399 ## the protection of multiple builds during a given call to MAKE.
400 ##
401 ## Catch signals SIGHUP (1), SIGINT (2), SIGPIPE (13), and SIGTERM
402 ## (15).  At a caught signal, the quoted command will be issued before
403 ## exiting.  In this case, remove any stamp, whether temporary of not.
404 ## The trap is valid until the process exits; the process includes all
405 ## commands appended via "\"s.
406 ##
407         trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_general-generate-*' 1 2 13 15; \
408 ##
409 ## Create a temporary directory, which acts as a lock.  The first
410 ## process to create the directory will succeed and issue the MAKE
411 ## command to do the actual work, while all subsequent processes will
412 ## fail -- leading them to wait for the first process to finish.
413 ##
414         if mkdir $(DEPDIR)/gnuradio_swig_py_general-generate-lock 2>/dev/null; then \
415 ##
416 ## This code is being executed by the first process to succeed in
417 ## creating the directory lock.
418 ##
419 ## Remove the stamp associated with this filename.
420 ##
421                 rm -f $(DEPDIR)/gnuradio_swig_py_general-generate-stamp; \
422 ##
423 ## Tell MAKE to run the rule for creating this stamp.
424 ##
425                 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_general-generate-stamp WHAT=$<; \
426 ##
427 ## Now that the .cc, .h, and .py files have been (re)created from the
428 ## .i file, future checking of this rule during the same MAKE
429 ## execution will come back that the rule doesn't need to be executed
430 ## because none of the conditions mentioned at the start of this rule
431 ## will be positive.  Remove the the directory lock, which frees up
432 ## any waiting process(es) to continue.
433 ##
434                 rmdir $(DEPDIR)/gnuradio_swig_py_general-generate-lock; \
435         else \
436 ##
437 ## This code is being executed by any follower processes while the
438 ## directory lock is in place.
439 ##
440 ## Wait until the first process is done, testing once per second.
441 ##
442                 while test -d $(DEPDIR)/gnuradio_swig_py_general-generate-lock; do \
443                         sleep 1; \
444                 done; \
445 ##
446 ## Succeed if and only if the first process succeeded; exit this
447 ## process returning the status of the generated stamp.
448 ##
449                 test -f $(DEPDIR)/gnuradio_swig_py_general-generate-stamp; \
450                 exit $$?; \
451         fi;
452
453 $(DEPDIR)/gnuradio_swig_py_general-generate-stamp:
454 ## This rule will be called only by the first process issuing the
455 ## above rule to succeed in creating the lock directory, after
456 ## removing the actual stamp file in order to guarantee that MAKE will
457 ## execute this rule.
458 ##
459 ## Call SWIG to generate the various output files; special
460 ## post-processing on 'mingw32' host OS for the dependency file.
461 ##
462         if $(SWIG) $(STD_SWIG_PYTHON_ARGS) $(gnuradio_swig_py_general_swig_args) \
463                 -MD -MF $(DEPDIR)/gnuradio_swig_py_general.Std \
464                 -module gnuradio_swig_py_general -o gnuradio_swig_py_general.cc $(WHAT); then \
465             if test $(host_os) = mingw32; then \
466                 $(RM) $(DEPDIR)/gnuradio_swig_py_general.Sd; \
467                 $(SED) 's,\\\\,/,g' < $(DEPDIR)/gnuradio_swig_py_general.Std \
468                         > $(DEPDIR)/gnuradio_swig_py_general.Sd; \
469                 $(RM) $(DEPDIR)/gnuradio_swig_py_general.Std; \
470                 $(MV) $(DEPDIR)/gnuradio_swig_py_general.Sd $(DEPDIR)/gnuradio_swig_py_general.Std; \
471             fi; \
472         else \
473             $(RM) $(DEPDIR)/gnuradio_swig_py_general.S*; exit 1; \
474         fi;
475 ##
476 ## Mess with the SWIG output .Std dependency file, to create a
477 ## dependecy file valid for the input .i file: Basically, simulate the
478 ## dependency file created for libraries by GNU's libtool for C++,
479 ## where all of the dependencies for the target are first listed, then
480 ## each individual dependency is listed as a target with no further
481 ## dependencies.
482 ##
483 ## (1) remove the current dependency file
484 ##
485         $(RM) $(DEPDIR)/gnuradio_swig_py_general.d
486 ##
487 ## (2) Copy the whole SWIG file:
488 ##
489         cp $(DEPDIR)/gnuradio_swig_py_general.Std $(DEPDIR)/gnuradio_swig_py_general.d
490 ##
491 ## (3) all a carriage return to the end of the dependency file.
492 ##
493         echo "" >> $(DEPDIR)/gnuradio_swig_py_general.d
494 ##
495 ## (4) from the SWIG file, remove the first line (the target); remove
496 ##     trailing " \" and " " from each line.  Append ":" to each line,
497 ##     followed by 2 carriage returns, then append this to the end of
498 ##     the dependency file.
499 ##
500         $(SED) -e '1d;s, \\,,g;s, ,,g' < $(DEPDIR)/gnuradio_swig_py_general.Std | \
501                 awk '{ printf "%s:\n\n", $$0 }' >> $(DEPDIR)/gnuradio_swig_py_general.d
502 ##
503 ## (5) remove the SWIG-generated file
504 ##
505         $(RM) $(DEPDIR)/gnuradio_swig_py_general.Std
506 ##
507 ## Create the stamp for this filename generation, to signal success in
508 ## executing this rule; allows other threads waiting on this process
509 ## to continue.
510 ##
511         touch $(DEPDIR)/gnuradio_swig_py_general-generate-stamp
512
513 # KLUDGE: Force runtime include of a SWIG dependency file.  This is
514 # not guaranteed to be portable, but will probably work.  If it works,
515 # we have accurate dependencies for our swig stuff, which is good.
516
517 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_general.d@am__quote@
518
519 # -*- Makefile -*-
520 #
521 # Copyright 2009 Free Software Foundation, Inc.
522
523 # This file is part of GNU Radio
524
525 # GNU Radio is free software; you can redistribute it and/or modify
526 # it under the terms of the GNU General Public License as published by
527 # the Free Software Foundation; either version 3, or (at your option)
528 # any later version.
529
530 # GNU Radio is distributed in the hope that it will be useful,
531 # but WITHOUT ANY WARRANTY; without even the implied warranty of
532 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
533 # GNU General Public License for more details.
534
535 # You should have received a copy of the GNU General Public License
536 # along with GNU Radio; see the file COPYING.  If not, write to
537 # the Free Software Foundation, Inc., 51 Franklin Street,
538 # Boston, MA 02110-1301, USA.
539
540
541 # Makefile.swig.gen for gnuradio_swig_py_gengen.i
542
543 ## Default install locations for these files:
544 ##
545 ## Default location for the Python directory is:
546 ##  ${prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_gengen
547 ## Default location for the Python exec directory is:
548 ##  ${exec_prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_gengen
549 ##
550 ## The following can be overloaded to change the install location, but
551 ## this has to be done in the including Makefile.am -before-
552 ## Makefile.swig is included.
553
554 gnuradio_swig_py_gengen_pythondir_category ?= gnuradio/gnuradio_swig_py_gengen
555 gnuradio_swig_py_gengen_pylibdir_category ?= $(gnuradio_swig_py_gengen_pythondir_category)
556 gnuradio_swig_py_gengen_pythondir = $(pythondir)/$(gnuradio_swig_py_gengen_pythondir_category)
557 gnuradio_swig_py_gengen_pylibdir = $(pyexecdir)/$(gnuradio_swig_py_gengen_pylibdir_category)
558
559 ## SWIG headers are always installed into the same directory.
560
561 gnuradio_swig_py_gengen_swigincludedir = $(swigincludedir)
562
563 ## This is a template file for a "generated" Makefile addition (in
564 ## this case, "Makefile.swig.gen").  By including the top-level
565 ## Makefile.swig, this file will be used to generate the SWIG
566 ## dependencies.  Assign the variable TOP_SWIG_FILES to be the list of
567 ## SWIG .i files to generated wrappings for; there can be more than 1
568 ## so long as the names are unique (no sorting is done on the
569 ## TOP_SWIG_FILES list). This file explicitly assumes that a SWIG .i
570 ## file will generate .cc, .py, and possibly .h files -- meaning that
571 ## all of these files will have the same base name (that provided for
572 ## the SWIG .i file).
573 ##
574 ## This code is setup to ensure parallel MAKE ("-j" or "-jN") does the
575 ## right thing.  For more info, see <
576 ## http://sources.redhat.com/automake/automake.html#Multiple-Outputs >
577
578 ## Stamps used to ensure parallel make does the right thing.  These
579 ## are removed by "make clean", but otherwise unused except during the
580 ## parallel built.  These will not be included in a tarball, because
581 ## the SWIG-generated files will be removed from the distribution.
582
583 STAMPS += $(DEPDIR)/gnuradio_swig_py_gengen-generate-*
584
585 ## Other cleaned files: dependency files generated by SWIG or this Makefile
586
587 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
588
589 ## Add the .py and .cc files to the list of SWIG built sources.  The
590 ## .h file is sometimes built, but not always ... so that one has to
591 ## be added manually by the including Makefile.am .
592
593 swig_built_sources += gnuradio_swig_py_gengen.py gnuradio_swig_py_gengen.cc
594
595 ## Various SWIG variables.  These can be overloaded in the including
596 ## Makefile.am by setting the variable value there, then including
597 ## Makefile.swig .
598
599 gnuradio_swig_py_gengen_swiginclude_HEADERS =           \
600         gnuradio_swig_py_gengen.i                       \
601         $(gnuradio_swig_py_gengen_swiginclude_headers)
602
603 gnuradio_swig_py_gengen_pylib_LTLIBRARIES =             \
604         _gnuradio_swig_py_gengen.la
605
606 _gnuradio_swig_py_gengen_la_SOURCES =                   \
607         gnuradio_swig_py_gengen.cc                      \
608         $(gnuradio_swig_py_gengen_la_swig_sources)
609
610 _gnuradio_swig_py_gengen_la_LIBADD =                    \
611         $(STD_SWIG_LA_LIB_ADD)          \
612         $(gnuradio_swig_py_gengen_la_swig_libadd)
613
614 _gnuradio_swig_py_gengen_la_LDFLAGS =                   \
615         $(STD_SWIG_LA_LD_FLAGS)         \
616         $(gnuradio_swig_py_gengen_la_swig_ldflags)
617
618 _gnuradio_swig_py_gengen_la_CXXFLAGS =                  \
619         $(STD_SWIG_CXX_FLAGS)           \
620         $(gnuradio_swig_py_gengen_la_swig_cxxflags)
621
622 gnuradio_swig_py_gengen_python_PYTHON =                 \
623         gnuradio_swig_py_gengen.py                      \
624         $(gnuradio_swig_py_gengen_python)
625
626 ## Entry rule for running SWIG
627
628 gnuradio_swig_py_gengen.h gnuradio_swig_py_gengen.py gnuradio_swig_py_gengen.cc: gnuradio_swig_py_gengen.i
629 ## This rule will get called only when MAKE decides that one of the
630 ## targets needs to be created or re-created, because:
631 ##
632 ## * The .i file is newer than any or all of the generated files;
633 ##
634 ## * Any or all of the .cc, .h, or .py files does not exist and is
635 ##   needed (in the case this file is not needed, the rule for it is
636 ##   ignored); or
637 ##
638 ## * Some SWIG-based dependecy of the .cc file isn't met and hence the
639 ##   .cc file needs be be regenerated.  Explanation: Because MAKE
640 ##   knows how to handle dependencies for .cc files (regardless of
641 ##   their name or extension), then the .cc file is used as a target
642 ##   instead of the .i file -- but with the dependencies of the .i
643 ##   file.  It is this last reason why the line:
644 ##
645 ##      if test -f $@; then :; else
646 ##
647 ##   cannot be used in this case: If a .i file dependecy is not met,
648 ##   then the .cc file needs to be rebuilt.  But if the stamp is newer
649 ##   than the .cc file, and the .cc file exists, then in the original
650 ##   version (with the 'test' above) the internal MAKE call will not
651 ##   be issued and hence the .cc file will not be rebuilt.
652 ##
653 ## Once execution gets to here, it should always proceed no matter the
654 ## state of a stamp (as discussed in link above).  The
655 ## $(DEPDIR)/gnuradio_swig_py_gengen-generate stuff is used to allow for parallel
656 ## builds to "do the right thing".  The stamp has no relationship with
657 ## either the target files or dependency file; it is used solely for
658 ## the protection of multiple builds during a given call to MAKE.
659 ##
660 ## Catch signals SIGHUP (1), SIGINT (2), SIGPIPE (13), and SIGTERM
661 ## (15).  At a caught signal, the quoted command will be issued before
662 ## exiting.  In this case, remove any stamp, whether temporary of not.
663 ## The trap is valid until the process exits; the process includes all
664 ## commands appended via "\"s.
665 ##
666         trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_gengen-generate-*' 1 2 13 15; \
667 ##
668 ## Create a temporary directory, which acts as a lock.  The first
669 ## process to create the directory will succeed and issue the MAKE
670 ## command to do the actual work, while all subsequent processes will
671 ## fail -- leading them to wait for the first process to finish.
672 ##
673         if mkdir $(DEPDIR)/gnuradio_swig_py_gengen-generate-lock 2>/dev/null; then \
674 ##
675 ## This code is being executed by the first process to succeed in
676 ## creating the directory lock.
677 ##
678 ## Remove the stamp associated with this filename.
679 ##
680                 rm -f $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp; \
681 ##
682 ## Tell MAKE to run the rule for creating this stamp.
683 ##
684                 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp WHAT=$<; \
685 ##
686 ## Now that the .cc, .h, and .py files have been (re)created from the
687 ## .i file, future checking of this rule during the same MAKE
688 ## execution will come back that the rule doesn't need to be executed
689 ## because none of the conditions mentioned at the start of this rule
690 ## will be positive.  Remove the the directory lock, which frees up
691 ## any waiting process(es) to continue.
692 ##
693                 rmdir $(DEPDIR)/gnuradio_swig_py_gengen-generate-lock; \
694         else \
695 ##
696 ## This code is being executed by any follower processes while the
697 ## directory lock is in place.
698 ##
699 ## Wait until the first process is done, testing once per second.
700 ##
701                 while test -d $(DEPDIR)/gnuradio_swig_py_gengen-generate-lock; do \
702                         sleep 1; \
703                 done; \
704 ##
705 ## Succeed if and only if the first process succeeded; exit this
706 ## process returning the status of the generated stamp.
707 ##
708                 test -f $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp; \
709                 exit $$?; \
710         fi;
711
712 $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp:
713 ## This rule will be called only by the first process issuing the
714 ## above rule to succeed in creating the lock directory, after
715 ## removing the actual stamp file in order to guarantee that MAKE will
716 ## execute this rule.
717 ##
718 ## Call SWIG to generate the various output files; special
719 ## post-processing on 'mingw32' host OS for the dependency file.
720 ##
721         if $(SWIG) $(STD_SWIG_PYTHON_ARGS) $(gnuradio_swig_py_gengen_swig_args) \
722                 -MD -MF $(DEPDIR)/gnuradio_swig_py_gengen.Std \
723                 -module gnuradio_swig_py_gengen -o gnuradio_swig_py_gengen.cc $(WHAT); then \
724             if test $(host_os) = mingw32; then \
725                 $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.Sd; \
726                 $(SED) 's,\\\\,/,g' < $(DEPDIR)/gnuradio_swig_py_gengen.Std \
727                         > $(DEPDIR)/gnuradio_swig_py_gengen.Sd; \
728                 $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.Std; \
729                 $(MV) $(DEPDIR)/gnuradio_swig_py_gengen.Sd $(DEPDIR)/gnuradio_swig_py_gengen.Std; \
730             fi; \
731         else \
732             $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.S*; exit 1; \
733         fi;
734 ##
735 ## Mess with the SWIG output .Std dependency file, to create a
736 ## dependecy file valid for the input .i file: Basically, simulate the
737 ## dependency file created for libraries by GNU's libtool for C++,
738 ## where all of the dependencies for the target are first listed, then
739 ## each individual dependency is listed as a target with no further
740 ## dependencies.
741 ##
742 ## (1) remove the current dependency file
743 ##
744         $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.d
745 ##
746 ## (2) Copy the whole SWIG file:
747 ##
748         cp $(DEPDIR)/gnuradio_swig_py_gengen.Std $(DEPDIR)/gnuradio_swig_py_gengen.d
749 ##
750 ## (3) all a carriage return to the end of the dependency file.
751 ##
752         echo "" >> $(DEPDIR)/gnuradio_swig_py_gengen.d
753 ##
754 ## (4) from the SWIG file, remove the first line (the target); remove
755 ##     trailing " \" and " " from each line.  Append ":" to each line,
756 ##     followed by 2 carriage returns, then append this to the end of
757 ##     the dependency file.
758 ##
759         $(SED) -e '1d;s, \\,,g;s, ,,g' < $(DEPDIR)/gnuradio_swig_py_gengen.Std | \
760                 awk '{ printf "%s:\n\n", $$0 }' >> $(DEPDIR)/gnuradio_swig_py_gengen.d
761 ##
762 ## (5) remove the SWIG-generated file
763 ##
764         $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.Std
765 ##
766 ## Create the stamp for this filename generation, to signal success in
767 ## executing this rule; allows other threads waiting on this process
768 ## to continue.
769 ##
770         touch $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp
771
772 # KLUDGE: Force runtime include of a SWIG dependency file.  This is
773 # not guaranteed to be portable, but will probably work.  If it works,
774 # we have accurate dependencies for our swig stuff, which is good.
775
776 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_gengen.d@am__quote@
777
778 # -*- Makefile -*-
779 #
780 # Copyright 2009 Free Software Foundation, Inc.
781
782 # This file is part of GNU Radio
783
784 # GNU Radio is free software; you can redistribute it and/or modify
785 # it under the terms of the GNU General Public License as published by
786 # the Free Software Foundation; either version 3, or (at your option)
787 # any later version.
788
789 # GNU Radio is distributed in the hope that it will be useful,
790 # but WITHOUT ANY WARRANTY; without even the implied warranty of
791 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
792 # GNU General Public License for more details.
793
794 # You should have received a copy of the GNU General Public License
795 # along with GNU Radio; see the file COPYING.  If not, write to
796 # the Free Software Foundation, Inc., 51 Franklin Street,
797 # Boston, MA 02110-1301, USA.
798
799
800 # Makefile.swig.gen for gnuradio_swig_py_filter.i
801
802 ## Default install locations for these files:
803 ##
804 ## Default location for the Python directory is:
805 ##  ${prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_filter
806 ## Default location for the Python exec directory is:
807 ##  ${exec_prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_filter
808 ##
809 ## The following can be overloaded to change the install location, but
810 ## this has to be done in the including Makefile.am -before-
811 ## Makefile.swig is included.
812
813 gnuradio_swig_py_filter_pythondir_category ?= gnuradio/gnuradio_swig_py_filter
814 gnuradio_swig_py_filter_pylibdir_category ?= $(gnuradio_swig_py_filter_pythondir_category)
815 gnuradio_swig_py_filter_pythondir = $(pythondir)/$(gnuradio_swig_py_filter_pythondir_category)
816 gnuradio_swig_py_filter_pylibdir = $(pyexecdir)/$(gnuradio_swig_py_filter_pylibdir_category)
817
818 ## SWIG headers are always installed into the same directory.
819
820 gnuradio_swig_py_filter_swigincludedir = $(swigincludedir)
821
822 ## This is a template file for a "generated" Makefile addition (in
823 ## this case, "Makefile.swig.gen").  By including the top-level
824 ## Makefile.swig, this file will be used to generate the SWIG
825 ## dependencies.  Assign the variable TOP_SWIG_FILES to be the list of
826 ## SWIG .i files to generated wrappings for; there can be more than 1
827 ## so long as the names are unique (no sorting is done on the
828 ## TOP_SWIG_FILES list). This file explicitly assumes that a SWIG .i
829 ## file will generate .cc, .py, and possibly .h files -- meaning that
830 ## all of these files will have the same base name (that provided for
831 ## the SWIG .i file).
832 ##
833 ## This code is setup to ensure parallel MAKE ("-j" or "-jN") does the
834 ## right thing.  For more info, see <
835 ## http://sources.redhat.com/automake/automake.html#Multiple-Outputs >
836
837 ## Stamps used to ensure parallel make does the right thing.  These
838 ## are removed by "make clean", but otherwise unused except during the
839 ## parallel built.  These will not be included in a tarball, because
840 ## the SWIG-generated files will be removed from the distribution.
841
842 STAMPS += $(DEPDIR)/gnuradio_swig_py_filter-generate-*
843
844 ## Other cleaned files: dependency files generated by SWIG or this Makefile
845
846 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
847
848 ## Add the .py and .cc files to the list of SWIG built sources.  The
849 ## .h file is sometimes built, but not always ... so that one has to
850 ## be added manually by the including Makefile.am .
851
852 swig_built_sources += gnuradio_swig_py_filter.py gnuradio_swig_py_filter.cc
853
854 ## Various SWIG variables.  These can be overloaded in the including
855 ## Makefile.am by setting the variable value there, then including
856 ## Makefile.swig .
857
858 gnuradio_swig_py_filter_swiginclude_HEADERS =           \
859         gnuradio_swig_py_filter.i                       \
860         $(gnuradio_swig_py_filter_swiginclude_headers)
861
862 gnuradio_swig_py_filter_pylib_LTLIBRARIES =             \
863         _gnuradio_swig_py_filter.la
864
865 _gnuradio_swig_py_filter_la_SOURCES =                   \
866         gnuradio_swig_py_filter.cc                      \
867         $(gnuradio_swig_py_filter_la_swig_sources)
868
869 _gnuradio_swig_py_filter_la_LIBADD =                    \
870         $(STD_SWIG_LA_LIB_ADD)          \
871         $(gnuradio_swig_py_filter_la_swig_libadd)
872
873 _gnuradio_swig_py_filter_la_LDFLAGS =                   \
874         $(STD_SWIG_LA_LD_FLAGS)         \
875         $(gnuradio_swig_py_filter_la_swig_ldflags)
876
877 _gnuradio_swig_py_filter_la_CXXFLAGS =                  \
878         $(STD_SWIG_CXX_FLAGS)           \
879         $(gnuradio_swig_py_filter_la_swig_cxxflags)
880
881 gnuradio_swig_py_filter_python_PYTHON =                 \
882         gnuradio_swig_py_filter.py                      \
883         $(gnuradio_swig_py_filter_python)
884
885 ## Entry rule for running SWIG
886
887 gnuradio_swig_py_filter.h gnuradio_swig_py_filter.py gnuradio_swig_py_filter.cc: gnuradio_swig_py_filter.i
888 ## This rule will get called only when MAKE decides that one of the
889 ## targets needs to be created or re-created, because:
890 ##
891 ## * The .i file is newer than any or all of the generated files;
892 ##
893 ## * Any or all of the .cc, .h, or .py files does not exist and is
894 ##   needed (in the case this file is not needed, the rule for it is
895 ##   ignored); or
896 ##
897 ## * Some SWIG-based dependecy of the .cc file isn't met and hence the
898 ##   .cc file needs be be regenerated.  Explanation: Because MAKE
899 ##   knows how to handle dependencies for .cc files (regardless of
900 ##   their name or extension), then the .cc file is used as a target
901 ##   instead of the .i file -- but with the dependencies of the .i
902 ##   file.  It is this last reason why the line:
903 ##
904 ##      if test -f $@; then :; else
905 ##
906 ##   cannot be used in this case: If a .i file dependecy is not met,
907 ##   then the .cc file needs to be rebuilt.  But if the stamp is newer
908 ##   than the .cc file, and the .cc file exists, then in the original
909 ##   version (with the 'test' above) the internal MAKE call will not
910 ##   be issued and hence the .cc file will not be rebuilt.
911 ##
912 ## Once execution gets to here, it should always proceed no matter the
913 ## state of a stamp (as discussed in link above).  The
914 ## $(DEPDIR)/gnuradio_swig_py_filter-generate stuff is used to allow for parallel
915 ## builds to "do the right thing".  The stamp has no relationship with
916 ## either the target files or dependency file; it is used solely for
917 ## the protection of multiple builds during a given call to MAKE.
918 ##
919 ## Catch signals SIGHUP (1), SIGINT (2), SIGPIPE (13), and SIGTERM
920 ## (15).  At a caught signal, the quoted command will be issued before
921 ## exiting.  In this case, remove any stamp, whether temporary of not.
922 ## The trap is valid until the process exits; the process includes all
923 ## commands appended via "\"s.
924 ##
925         trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_filter-generate-*' 1 2 13 15; \
926 ##
927 ## Create a temporary directory, which acts as a lock.  The first
928 ## process to create the directory will succeed and issue the MAKE
929 ## command to do the actual work, while all subsequent processes will
930 ## fail -- leading them to wait for the first process to finish.
931 ##
932         if mkdir $(DEPDIR)/gnuradio_swig_py_filter-generate-lock 2>/dev/null; then \
933 ##
934 ## This code is being executed by the first process to succeed in
935 ## creating the directory lock.
936 ##
937 ## Remove the stamp associated with this filename.
938 ##
939                 rm -f $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp; \
940 ##
941 ## Tell MAKE to run the rule for creating this stamp.
942 ##
943                 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp WHAT=$<; \
944 ##
945 ## Now that the .cc, .h, and .py files have been (re)created from the
946 ## .i file, future checking of this rule during the same MAKE
947 ## execution will come back that the rule doesn't need to be executed
948 ## because none of the conditions mentioned at the start of this rule
949 ## will be positive.  Remove the the directory lock, which frees up
950 ## any waiting process(es) to continue.
951 ##
952                 rmdir $(DEPDIR)/gnuradio_swig_py_filter-generate-lock; \
953         else \
954 ##
955 ## This code is being executed by any follower processes while the
956 ## directory lock is in place.
957 ##
958 ## Wait until the first process is done, testing once per second.
959 ##
960                 while test -d $(DEPDIR)/gnuradio_swig_py_filter-generate-lock; do \
961                         sleep 1; \
962                 done; \
963 ##
964 ## Succeed if and only if the first process succeeded; exit this
965 ## process returning the status of the generated stamp.
966 ##
967                 test -f $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp; \
968                 exit $$?; \
969         fi;
970
971 $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp:
972 ## This rule will be called only by the first process issuing the
973 ## above rule to succeed in creating the lock directory, after
974 ## removing the actual stamp file in order to guarantee that MAKE will
975 ## execute this rule.
976 ##
977 ## Call SWIG to generate the various output files; special
978 ## post-processing on 'mingw32' host OS for the dependency file.
979 ##
980         if $(SWIG) $(STD_SWIG_PYTHON_ARGS) $(gnuradio_swig_py_filter_swig_args) \
981                 -MD -MF $(DEPDIR)/gnuradio_swig_py_filter.Std \
982                 -module gnuradio_swig_py_filter -o gnuradio_swig_py_filter.cc $(WHAT); then \
983             if test $(host_os) = mingw32; then \
984                 $(RM) $(DEPDIR)/gnuradio_swig_py_filter.Sd; \
985                 $(SED) 's,\\\\,/,g' < $(DEPDIR)/gnuradio_swig_py_filter.Std \
986                         > $(DEPDIR)/gnuradio_swig_py_filter.Sd; \
987                 $(RM) $(DEPDIR)/gnuradio_swig_py_filter.Std; \
988                 $(MV) $(DEPDIR)/gnuradio_swig_py_filter.Sd $(DEPDIR)/gnuradio_swig_py_filter.Std; \
989             fi; \
990         else \
991             $(RM) $(DEPDIR)/gnuradio_swig_py_filter.S*; exit 1; \
992         fi;
993 ##
994 ## Mess with the SWIG output .Std dependency file, to create a
995 ## dependecy file valid for the input .i file: Basically, simulate the
996 ## dependency file created for libraries by GNU's libtool for C++,
997 ## where all of the dependencies for the target are first listed, then
998 ## each individual dependency is listed as a target with no further
999 ## dependencies.
1000 ##
1001 ## (1) remove the current dependency file
1002 ##
1003         $(RM) $(DEPDIR)/gnuradio_swig_py_filter.d
1004 ##
1005 ## (2) Copy the whole SWIG file:
1006 ##
1007         cp $(DEPDIR)/gnuradio_swig_py_filter.Std $(DEPDIR)/gnuradio_swig_py_filter.d
1008 ##
1009 ## (3) all a carriage return to the end of the dependency file.
1010 ##
1011         echo "" >> $(DEPDIR)/gnuradio_swig_py_filter.d
1012 ##
1013 ## (4) from the SWIG file, remove the first line (the target); remove
1014 ##     trailing " \" and " " from each line.  Append ":" to each line,
1015 ##     followed by 2 carriage returns, then append this to the end of
1016 ##     the dependency file.
1017 ##
1018         $(SED) -e '1d;s, \\,,g;s, ,,g' < $(DEPDIR)/gnuradio_swig_py_filter.Std | \
1019                 awk '{ printf "%s:\n\n", $$0 }' >> $(DEPDIR)/gnuradio_swig_py_filter.d
1020 ##
1021 ## (5) remove the SWIG-generated file
1022 ##
1023         $(RM) $(DEPDIR)/gnuradio_swig_py_filter.Std
1024 ##
1025 ## Create the stamp for this filename generation, to signal success in
1026 ## executing this rule; allows other threads waiting on this process
1027 ## to continue.
1028 ##
1029         touch $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp
1030
1031 # KLUDGE: Force runtime include of a SWIG dependency file.  This is
1032 # not guaranteed to be portable, but will probably work.  If it works,
1033 # we have accurate dependencies for our swig stuff, which is good.
1034
1035 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_filter.d@am__quote@
1036
1037 # -*- Makefile -*-
1038 #
1039 # Copyright 2009 Free Software Foundation, Inc.
1040
1041 # This file is part of GNU Radio
1042
1043 # GNU Radio is free software; you can redistribute it and/or modify
1044 # it under the terms of the GNU General Public License as published by
1045 # the Free Software Foundation; either version 3, or (at your option)
1046 # any later version.
1047
1048 # GNU Radio is distributed in the hope that it will be useful,
1049 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1050 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1051 # GNU General Public License for more details.
1052
1053 # You should have received a copy of the GNU General Public License
1054 # along with GNU Radio; see the file COPYING.  If not, write to
1055 # the Free Software Foundation, Inc., 51 Franklin Street,
1056 # Boston, MA 02110-1301, USA.
1057
1058
1059 # Makefile.swig.gen for gnuradio_swig_py_io.i
1060
1061 ## Default install locations for these files:
1062 ##
1063 ## Default location for the Python directory is:
1064 ##  ${prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_io
1065 ## Default location for the Python exec directory is:
1066 ##  ${exec_prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_io
1067 ##
1068 ## The following can be overloaded to change the install location, but
1069 ## this has to be done in the including Makefile.am -before-
1070 ## Makefile.swig is included.
1071
1072 gnuradio_swig_py_io_pythondir_category ?= gnuradio/gnuradio_swig_py_io
1073 gnuradio_swig_py_io_pylibdir_category ?= $(gnuradio_swig_py_io_pythondir_category)
1074 gnuradio_swig_py_io_pythondir = $(pythondir)/$(gnuradio_swig_py_io_pythondir_category)
1075 gnuradio_swig_py_io_pylibdir = $(pyexecdir)/$(gnuradio_swig_py_io_pylibdir_category)
1076
1077 ## SWIG headers are always installed into the same directory.
1078
1079 gnuradio_swig_py_io_swigincludedir = $(swigincludedir)
1080
1081 ## This is a template file for a "generated" Makefile addition (in
1082 ## this case, "Makefile.swig.gen").  By including the top-level
1083 ## Makefile.swig, this file will be used to generate the SWIG
1084 ## dependencies.  Assign the variable TOP_SWIG_FILES to be the list of
1085 ## SWIG .i files to generated wrappings for; there can be more than 1
1086 ## so long as the names are unique (no sorting is done on the
1087 ## TOP_SWIG_FILES list). This file explicitly assumes that a SWIG .i
1088 ## file will generate .cc, .py, and possibly .h files -- meaning that
1089 ## all of these files will have the same base name (that provided for
1090 ## the SWIG .i file).
1091 ##
1092 ## This code is setup to ensure parallel MAKE ("-j" or "-jN") does the
1093 ## right thing.  For more info, see <
1094 ## http://sources.redhat.com/automake/automake.html#Multiple-Outputs >
1095
1096 ## Stamps used to ensure parallel make does the right thing.  These
1097 ## are removed by "make clean", but otherwise unused except during the
1098 ## parallel built.  These will not be included in a tarball, because
1099 ## the SWIG-generated files will be removed from the distribution.
1100
1101 STAMPS += $(DEPDIR)/gnuradio_swig_py_io-generate-*
1102
1103 ## Other cleaned files: dependency files generated by SWIG or this Makefile
1104
1105 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
1106
1107 ## Add the .py and .cc files to the list of SWIG built sources.  The
1108 ## .h file is sometimes built, but not always ... so that one has to
1109 ## be added manually by the including Makefile.am .
1110
1111 swig_built_sources += gnuradio_swig_py_io.py gnuradio_swig_py_io.cc
1112
1113 ## Various SWIG variables.  These can be overloaded in the including
1114 ## Makefile.am by setting the variable value there, then including
1115 ## Makefile.swig .
1116
1117 gnuradio_swig_py_io_swiginclude_HEADERS =               \
1118         gnuradio_swig_py_io.i                   \
1119         $(gnuradio_swig_py_io_swiginclude_headers)
1120
1121 gnuradio_swig_py_io_pylib_LTLIBRARIES =         \
1122         _gnuradio_swig_py_io.la
1123
1124 _gnuradio_swig_py_io_la_SOURCES =                       \
1125         gnuradio_swig_py_io.cc                  \
1126         $(gnuradio_swig_py_io_la_swig_sources)
1127
1128 _gnuradio_swig_py_io_la_LIBADD =                        \
1129         $(STD_SWIG_LA_LIB_ADD)          \
1130         $(gnuradio_swig_py_io_la_swig_libadd)
1131
1132 _gnuradio_swig_py_io_la_LDFLAGS =                       \
1133         $(STD_SWIG_LA_LD_FLAGS)         \
1134         $(gnuradio_swig_py_io_la_swig_ldflags)
1135
1136 _gnuradio_swig_py_io_la_CXXFLAGS =                      \
1137         $(STD_SWIG_CXX_FLAGS)           \
1138         $(gnuradio_swig_py_io_la_swig_cxxflags)
1139
1140 gnuradio_swig_py_io_python_PYTHON =                     \
1141         gnuradio_swig_py_io.py                  \
1142         $(gnuradio_swig_py_io_python)
1143
1144 ## Entry rule for running SWIG
1145
1146 gnuradio_swig_py_io.h gnuradio_swig_py_io.py gnuradio_swig_py_io.cc: gnuradio_swig_py_io.i
1147 ## This rule will get called only when MAKE decides that one of the
1148 ## targets needs to be created or re-created, because:
1149 ##
1150 ## * The .i file is newer than any or all of the generated files;
1151 ##
1152 ## * Any or all of the .cc, .h, or .py files does not exist and is
1153 ##   needed (in the case this file is not needed, the rule for it is
1154 ##   ignored); or
1155 ##
1156 ## * Some SWIG-based dependecy of the .cc file isn't met and hence the
1157 ##   .cc file needs be be regenerated.  Explanation: Because MAKE
1158 ##   knows how to handle dependencies for .cc files (regardless of
1159 ##   their name or extension), then the .cc file is used as a target
1160 ##   instead of the .i file -- but with the dependencies of the .i
1161 ##   file.  It is this last reason why the line:
1162 ##
1163 ##      if test -f $@; then :; else
1164 ##
1165 ##   cannot be used in this case: If a .i file dependecy is not met,
1166 ##   then the .cc file needs to be rebuilt.  But if the stamp is newer
1167 ##   than the .cc file, and the .cc file exists, then in the original
1168 ##   version (with the 'test' above) the internal MAKE call will not
1169 ##   be issued and hence the .cc file will not be rebuilt.
1170 ##
1171 ## Once execution gets to here, it should always proceed no matter the
1172 ## state of a stamp (as discussed in link above).  The
1173 ## $(DEPDIR)/gnuradio_swig_py_io-generate stuff is used to allow for parallel
1174 ## builds to "do the right thing".  The stamp has no relationship with
1175 ## either the target files or dependency file; it is used solely for
1176 ## the protection of multiple builds during a given call to MAKE.
1177 ##
1178 ## Catch signals SIGHUP (1), SIGINT (2), SIGPIPE (13), and SIGTERM
1179 ## (15).  At a caught signal, the quoted command will be issued before
1180 ## exiting.  In this case, remove any stamp, whether temporary of not.
1181 ## The trap is valid until the process exits; the process includes all
1182 ## commands appended via "\"s.
1183 ##
1184         trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_io-generate-*' 1 2 13 15; \
1185 ##
1186 ## Create a temporary directory, which acts as a lock.  The first
1187 ## process to create the directory will succeed and issue the MAKE
1188 ## command to do the actual work, while all subsequent processes will
1189 ## fail -- leading them to wait for the first process to finish.
1190 ##
1191         if mkdir $(DEPDIR)/gnuradio_swig_py_io-generate-lock 2>/dev/null; then \
1192 ##
1193 ## This code is being executed by the first process to succeed in
1194 ## creating the directory lock.
1195 ##
1196 ## Remove the stamp associated with this filename.
1197 ##
1198                 rm -f $(DEPDIR)/gnuradio_swig_py_io-generate-stamp; \
1199 ##
1200 ## Tell MAKE to run the rule for creating this stamp.
1201 ##
1202                 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_io-generate-stamp WHAT=$<; \
1203 ##
1204 ## Now that the .cc, .h, and .py files have been (re)created from the
1205 ## .i file, future checking of this rule during the same MAKE
1206 ## execution will come back that the rule doesn't need to be executed
1207 ## because none of the conditions mentioned at the start of this rule
1208 ## will be positive.  Remove the the directory lock, which frees up
1209 ## any waiting process(es) to continue.
1210 ##
1211                 rmdir $(DEPDIR)/gnuradio_swig_py_io-generate-lock; \
1212         else \
1213 ##
1214 ## This code is being executed by any follower processes while the
1215 ## directory lock is in place.
1216 ##
1217 ## Wait until the first process is done, testing once per second.
1218 ##
1219                 while test -d $(DEPDIR)/gnuradio_swig_py_io-generate-lock; do \
1220                         sleep 1; \
1221                 done; \
1222 ##
1223 ## Succeed if and only if the first process succeeded; exit this
1224 ## process returning the status of the generated stamp.
1225 ##
1226                 test -f $(DEPDIR)/gnuradio_swig_py_io-generate-stamp; \
1227                 exit $$?; \
1228         fi;
1229
1230 $(DEPDIR)/gnuradio_swig_py_io-generate-stamp:
1231 ## This rule will be called only by the first process issuing the
1232 ## above rule to succeed in creating the lock directory, after
1233 ## removing the actual stamp file in order to guarantee that MAKE will
1234 ## execute this rule.
1235 ##
1236 ## Call SWIG to generate the various output files; special
1237 ## post-processing on 'mingw32' host OS for the dependency file.
1238 ##
1239         if $(SWIG) $(STD_SWIG_PYTHON_ARGS) $(gnuradio_swig_py_io_swig_args) \
1240                 -MD -MF $(DEPDIR)/gnuradio_swig_py_io.Std \
1241                 -module gnuradio_swig_py_io -o gnuradio_swig_py_io.cc $(WHAT); then \
1242             if test $(host_os) = mingw32; then \
1243                 $(RM) $(DEPDIR)/gnuradio_swig_py_io.Sd; \
1244                 $(SED) 's,\\\\,/,g' < $(DEPDIR)/gnuradio_swig_py_io.Std \
1245                         > $(DEPDIR)/gnuradio_swig_py_io.Sd; \
1246                 $(RM) $(DEPDIR)/gnuradio_swig_py_io.Std; \
1247                 $(MV) $(DEPDIR)/gnuradio_swig_py_io.Sd $(DEPDIR)/gnuradio_swig_py_io.Std; \
1248             fi; \
1249         else \
1250             $(RM) $(DEPDIR)/gnuradio_swig_py_io.S*; exit 1; \
1251         fi;
1252 ##
1253 ## Mess with the SWIG output .Std dependency file, to create a
1254 ## dependecy file valid for the input .i file: Basically, simulate the
1255 ## dependency file created for libraries by GNU's libtool for C++,
1256 ## where all of the dependencies for the target are first listed, then
1257 ## each individual dependency is listed as a target with no further
1258 ## dependencies.
1259 ##
1260 ## (1) remove the current dependency file
1261 ##
1262         $(RM) $(DEPDIR)/gnuradio_swig_py_io.d
1263 ##
1264 ## (2) Copy the whole SWIG file:
1265 ##
1266         cp $(DEPDIR)/gnuradio_swig_py_io.Std $(DEPDIR)/gnuradio_swig_py_io.d
1267 ##
1268 ## (3) all a carriage return to the end of the dependency file.
1269 ##
1270         echo "" >> $(DEPDIR)/gnuradio_swig_py_io.d
1271 ##
1272 ## (4) from the SWIG file, remove the first line (the target); remove
1273 ##     trailing " \" and " " from each line.  Append ":" to each line,
1274 ##     followed by 2 carriage returns, then append this to the end of
1275 ##     the dependency file.
1276 ##
1277         $(SED) -e '1d;s, \\,,g;s, ,,g' < $(DEPDIR)/gnuradio_swig_py_io.Std | \
1278                 awk '{ printf "%s:\n\n", $$0 }' >> $(DEPDIR)/gnuradio_swig_py_io.d
1279 ##
1280 ## (5) remove the SWIG-generated file
1281 ##
1282         $(RM) $(DEPDIR)/gnuradio_swig_py_io.Std
1283 ##
1284 ## Create the stamp for this filename generation, to signal success in
1285 ## executing this rule; allows other threads waiting on this process
1286 ## to continue.
1287 ##
1288         touch $(DEPDIR)/gnuradio_swig_py_io-generate-stamp
1289
1290 # KLUDGE: Force runtime include of a SWIG dependency file.  This is
1291 # not guaranteed to be portable, but will probably work.  If it works,
1292 # we have accurate dependencies for our swig stuff, which is good.
1293
1294 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_io.d@am__quote@
1295
1296 # -*- Makefile -*-
1297 #
1298 # Copyright 2009 Free Software Foundation, Inc.
1299
1300 # This file is part of GNU Radio
1301
1302 # GNU Radio is free software; you can redistribute it and/or modify
1303 # it under the terms of the GNU General Public License as published by
1304 # the Free Software Foundation; either version 3, or (at your option)
1305 # any later version.
1306
1307 # GNU Radio is distributed in the hope that it will be useful,
1308 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1309 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1310 # GNU General Public License for more details.
1311
1312 # You should have received a copy of the GNU General Public License
1313 # along with GNU Radio; see the file COPYING.  If not, write to
1314 # the Free Software Foundation, Inc., 51 Franklin Street,
1315 # Boston, MA 02110-1301, USA.
1316
1317
1318 # Makefile.swig.gen for gnuradio_swig_py_hier.i
1319
1320 ## Default install locations for these files:
1321 ##
1322 ## Default location for the Python directory is:
1323 ##  ${prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_hier
1324 ## Default location for the Python exec directory is:
1325 ##  ${exec_prefix}/lib/python${python_version}/site-packages/[category]/gnuradio_swig_py_hier
1326 ##
1327 ## The following can be overloaded to change the install location, but
1328 ## this has to be done in the including Makefile.am -before-
1329 ## Makefile.swig is included.
1330
1331 gnuradio_swig_py_hier_pythondir_category ?= gnuradio/gnuradio_swig_py_hier
1332 gnuradio_swig_py_hier_pylibdir_category ?= $(gnuradio_swig_py_hier_pythondir_category)
1333 gnuradio_swig_py_hier_pythondir = $(pythondir)/$(gnuradio_swig_py_hier_pythondir_category)
1334 gnuradio_swig_py_hier_pylibdir = $(pyexecdir)/$(gnuradio_swig_py_hier_pylibdir_category)
1335
1336 ## SWIG headers are always installed into the same directory.
1337
1338 gnuradio_swig_py_hier_swigincludedir = $(swigincludedir)
1339
1340 ## This is a template file for a "generated" Makefile addition (in
1341 ## this case, "Makefile.swig.gen").  By including the top-level
1342 ## Makefile.swig, this file will be used to generate the SWIG
1343 ## dependencies.  Assign the variable TOP_SWIG_FILES to be the list of
1344 ## SWIG .i files to generated wrappings for; there can be more than 1
1345 ## so long as the names are unique (no sorting is done on the
1346 ## TOP_SWIG_FILES list). This file explicitly assumes that a SWIG .i
1347 ## file will generate .cc, .py, and possibly .h files -- meaning that
1348 ## all of these files will have the same base name (that provided for
1349 ## the SWIG .i file).
1350 ##
1351 ## This code is setup to ensure parallel MAKE ("-j" or "-jN") does the
1352 ## right thing.  For more info, see <
1353 ## http://sources.redhat.com/automake/automake.html#Multiple-Outputs >
1354
1355 ## Stamps used to ensure parallel make does the right thing.  These
1356 ## are removed by "make clean", but otherwise unused except during the
1357 ## parallel built.  These will not be included in a tarball, because
1358 ## the SWIG-generated files will be removed from the distribution.
1359
1360 STAMPS += $(DEPDIR)/gnuradio_swig_py_hier-generate-*
1361
1362 ## Other cleaned files: dependency files generated by SWIG or this Makefile
1363
1364 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
1365
1366 ## Add the .py and .cc files to the list of SWIG built sources.  The
1367 ## .h file is sometimes built, but not always ... so that one has to
1368 ## be added manually by the including Makefile.am .
1369
1370 swig_built_sources += gnuradio_swig_py_hier.py gnuradio_swig_py_hier.cc
1371
1372 ## Various SWIG variables.  These can be overloaded in the including
1373 ## Makefile.am by setting the variable value there, then including
1374 ## Makefile.swig .
1375
1376 gnuradio_swig_py_hier_swiginclude_HEADERS =             \
1377         gnuradio_swig_py_hier.i                 \
1378         $(gnuradio_swig_py_hier_swiginclude_headers)
1379
1380 gnuradio_swig_py_hier_pylib_LTLIBRARIES =               \
1381         _gnuradio_swig_py_hier.la
1382
1383 _gnuradio_swig_py_hier_la_SOURCES =                     \
1384         gnuradio_swig_py_hier.cc                        \
1385         $(gnuradio_swig_py_hier_la_swig_sources)
1386
1387 _gnuradio_swig_py_hier_la_LIBADD =                      \
1388         $(STD_SWIG_LA_LIB_ADD)          \
1389         $(gnuradio_swig_py_hier_la_swig_libadd)
1390
1391 _gnuradio_swig_py_hier_la_LDFLAGS =                     \
1392         $(STD_SWIG_LA_LD_FLAGS)         \
1393         $(gnuradio_swig_py_hier_la_swig_ldflags)
1394
1395 _gnuradio_swig_py_hier_la_CXXFLAGS =                    \
1396         $(STD_SWIG_CXX_FLAGS)           \
1397         $(gnuradio_swig_py_hier_la_swig_cxxflags)
1398
1399 gnuradio_swig_py_hier_python_PYTHON =                   \
1400         gnuradio_swig_py_hier.py                        \
1401         $(gnuradio_swig_py_hier_python)
1402
1403 ## Entry rule for running SWIG
1404
1405 gnuradio_swig_py_hier.h gnuradio_swig_py_hier.py gnuradio_swig_py_hier.cc: gnuradio_swig_py_hier.i
1406 ## This rule will get called only when MAKE decides that one of the
1407 ## targets needs to be created or re-created, because:
1408 ##
1409 ## * The .i file is newer than any or all of the generated files;
1410 ##
1411 ## * Any or all of the .cc, .h, or .py files does not exist and is
1412 ##   needed (in the case this file is not needed, the rule for it is
1413 ##   ignored); or
1414 ##
1415 ## * Some SWIG-based dependecy of the .cc file isn't met and hence the
1416 ##   .cc file needs be be regenerated.  Explanation: Because MAKE
1417 ##   knows how to handle dependencies for .cc files (regardless of
1418 ##   their name or extension), then the .cc file is used as a target
1419 ##   instead of the .i file -- but with the dependencies of the .i
1420 ##   file.  It is this last reason why the line:
1421 ##
1422 ##      if test -f $@; then :; else
1423 ##
1424 ##   cannot be used in this case: If a .i file dependecy is not met,
1425 ##   then the .cc file needs to be rebuilt.  But if the stamp is newer
1426 ##   than the .cc file, and the .cc file exists, then in the original
1427 ##   version (with the 'test' above) the internal MAKE call will not
1428 ##   be issued and hence the .cc file will not be rebuilt.
1429 ##
1430 ## Once execution gets to here, it should always proceed no matter the
1431 ## state of a stamp (as discussed in link above).  The
1432 ## $(DEPDIR)/gnuradio_swig_py_hier-generate stuff is used to allow for parallel
1433 ## builds to "do the right thing".  The stamp has no relationship with
1434 ## either the target files or dependency file; it is used solely for
1435 ## the protection of multiple builds during a given call to MAKE.
1436 ##
1437 ## Catch signals SIGHUP (1), SIGINT (2), SIGPIPE (13), and SIGTERM
1438 ## (15).  At a caught signal, the quoted command will be issued before
1439 ## exiting.  In this case, remove any stamp, whether temporary of not.
1440 ## The trap is valid until the process exits; the process includes all
1441 ## commands appended via "\"s.
1442 ##
1443         trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_hier-generate-*' 1 2 13 15; \
1444 ##
1445 ## Create a temporary directory, which acts as a lock.  The first
1446 ## process to create the directory will succeed and issue the MAKE
1447 ## command to do the actual work, while all subsequent processes will
1448 ## fail -- leading them to wait for the first process to finish.
1449 ##
1450         if mkdir $(DEPDIR)/gnuradio_swig_py_hier-generate-lock 2>/dev/null; then \
1451 ##
1452 ## This code is being executed by the first process to succeed in
1453 ## creating the directory lock.
1454 ##
1455 ## Remove the stamp associated with this filename.
1456 ##
1457                 rm -f $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp; \
1458 ##
1459 ## Tell MAKE to run the rule for creating this stamp.
1460 ##
1461                 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp WHAT=$<; \
1462 ##
1463 ## Now that the .cc, .h, and .py files have been (re)created from the
1464 ## .i file, future checking of this rule during the same MAKE
1465 ## execution will come back that the rule doesn't need to be executed
1466 ## because none of the conditions mentioned at the start of this rule
1467 ## will be positive.  Remove the the directory lock, which frees up
1468 ## any waiting process(es) to continue.
1469 ##
1470                 rmdir $(DEPDIR)/gnuradio_swig_py_hier-generate-lock; \
1471         else \
1472 ##
1473 ## This code is being executed by any follower processes while the
1474 ## directory lock is in place.
1475 ##
1476 ## Wait until the first process is done, testing once per second.
1477 ##
1478                 while test -d $(DEPDIR)/gnuradio_swig_py_hier-generate-lock; do \
1479                         sleep 1; \
1480                 done; \
1481 ##
1482 ## Succeed if and only if the first process succeeded; exit this
1483 ## process returning the status of the generated stamp.
1484 ##
1485                 test -f $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp; \
1486                 exit $$?; \
1487         fi;
1488
1489 $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp:
1490 ## This rule will be called only by the first process issuing the
1491 ## above rule to succeed in creating the lock directory, after
1492 ## removing the actual stamp file in order to guarantee that MAKE will
1493 ## execute this rule.
1494 ##
1495 ## Call SWIG to generate the various output files; special
1496 ## post-processing on 'mingw32' host OS for the dependency file.
1497 ##
1498         if $(SWIG) $(STD_SWIG_PYTHON_ARGS) $(gnuradio_swig_py_hier_swig_args) \
1499                 -MD -MF $(DEPDIR)/gnuradio_swig_py_hier.Std \
1500                 -module gnuradio_swig_py_hier -o gnuradio_swig_py_hier.cc $(WHAT); then \
1501             if test $(host_os) = mingw32; then \
1502                 $(RM) $(DEPDIR)/gnuradio_swig_py_hier.Sd; \
1503                 $(SED) 's,\\\\,/,g' < $(DEPDIR)/gnuradio_swig_py_hier.Std \
1504                         > $(DEPDIR)/gnuradio_swig_py_hier.Sd; \
1505                 $(RM) $(DEPDIR)/gnuradio_swig_py_hier.Std; \
1506                 $(MV) $(DEPDIR)/gnuradio_swig_py_hier.Sd $(DEPDIR)/gnuradio_swig_py_hier.Std; \
1507             fi; \
1508         else \
1509             $(RM) $(DEPDIR)/gnuradio_swig_py_hier.S*; exit 1; \
1510         fi;
1511 ##
1512 ## Mess with the SWIG output .Std dependency file, to create a
1513 ## dependecy file valid for the input .i file: Basically, simulate the
1514 ## dependency file created for libraries by GNU's libtool for C++,
1515 ## where all of the dependencies for the target are first listed, then
1516 ## each individual dependency is listed as a target with no further
1517 ## dependencies.
1518 ##
1519 ## (1) remove the current dependency file
1520 ##
1521         $(RM) $(DEPDIR)/gnuradio_swig_py_hier.d
1522 ##
1523 ## (2) Copy the whole SWIG file:
1524 ##
1525         cp $(DEPDIR)/gnuradio_swig_py_hier.Std $(DEPDIR)/gnuradio_swig_py_hier.d
1526 ##
1527 ## (3) all a carriage return to the end of the dependency file.
1528 ##
1529         echo "" >> $(DEPDIR)/gnuradio_swig_py_hier.d
1530 ##
1531 ## (4) from the SWIG file, remove the first line (the target); remove
1532 ##     trailing " \" and " " from each line.  Append ":" to each line,
1533 ##     followed by 2 carriage returns, then append this to the end of
1534 ##     the dependency file.
1535 ##
1536         $(SED) -e '1d;s, \\,,g;s, ,,g' < $(DEPDIR)/gnuradio_swig_py_hier.Std | \
1537                 awk '{ printf "%s:\n\n", $$0 }' >> $(DEPDIR)/gnuradio_swig_py_hier.d
1538 ##
1539 ## (5) remove the SWIG-generated file
1540 ##
1541         $(RM) $(DEPDIR)/gnuradio_swig_py_hier.Std
1542 ##
1543 ## Create the stamp for this filename generation, to signal success in
1544 ## executing this rule; allows other threads waiting on this process
1545 ## to continue.
1546 ##
1547         touch $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp
1548
1549 # KLUDGE: Force runtime include of a SWIG dependency file.  This is
1550 # not guaranteed to be portable, but will probably work.  If it works,
1551 # we have accurate dependencies for our swig stuff, which is good.
1552
1553 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_hier.d@am__quote@
1554