3 # Copyright 2009 Free Software Foundation, Inc.
5 # This file is part of GNU Radio
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)
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.
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.
23 # Makefile.swig.gen for gnuradio_swig_py_runtime.i
25 ## Default install locations for these files:
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
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.
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)
41 ## SWIG headers are always installed into the same directory.
43 gnuradio_swig_py_runtime_swigincludedir = $(swigincludedir)
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
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 >
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.
65 STAMPS += $(DEPDIR)/gnuradio_swig_py_runtime-generate-*
67 ## Other cleaned files: dependency files generated by SWIG or this Makefile
69 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
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 .
75 swig_built_sources += gnuradio_swig_py_runtime.py gnuradio_swig_py_runtime.cc
77 ## Various SWIG variables. These can be overloaded in the including
78 ## Makefile.am by setting the variable value there, then including
81 gnuradio_swig_py_runtime_swiginclude_HEADERS = \
82 gnuradio_swig_py_runtime.i \
83 $(gnuradio_swig_py_runtime_swiginclude_headers)
85 gnuradio_swig_py_runtime_pylib_LTLIBRARIES = \
86 _gnuradio_swig_py_runtime.la
88 _gnuradio_swig_py_runtime_la_SOURCES = \
89 gnuradio_swig_py_runtime.cc \
90 $(gnuradio_swig_py_runtime_la_swig_sources)
92 _gnuradio_swig_py_runtime_la_LIBADD = \
93 $(STD_SWIG_LA_LIB_ADD) \
94 $(gnuradio_swig_py_runtime_la_swig_libadd)
96 _gnuradio_swig_py_runtime_la_LDFLAGS = \
97 $(STD_SWIG_LA_LD_FLAGS) \
98 $(gnuradio_swig_py_runtime_la_swig_ldflags)
100 _gnuradio_swig_py_runtime_la_CXXFLAGS = \
101 $(STD_SWIG_CXX_FLAGS) \
102 $(gnuradio_swig_py_runtime_la_swig_cxxflags)
104 gnuradio_swig_py_runtime_python_PYTHON = \
105 gnuradio_swig_py_runtime.py \
106 $(gnuradio_swig_py_runtime_python)
108 ## Entry rule for running SWIG
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:
114 ## * The .i file is newer than any or all of the generated files;
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
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:
127 ## if test -f $@; then :; else
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.
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.
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.
148 trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_runtime-generate-*' 1 2 13 15; \
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.
155 if mkdir $(DEPDIR)/gnuradio_swig_py_runtime-generate-lock 2>/dev/null; then \
157 ## This code is being executed by the first process to succeed in
158 ## creating the directory lock.
160 ## Remove the stamp associated with this filename.
162 rm -f $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp; \
164 ## Tell MAKE to run the rule for creating this stamp.
166 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp WHAT=$<; \
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.
175 rmdir $(DEPDIR)/gnuradio_swig_py_runtime-generate-lock; \
178 ## This code is being executed by any follower processes while the
179 ## directory lock is in place.
181 ## Wait until the first process is done, testing once per second.
183 while test -d $(DEPDIR)/gnuradio_swig_py_runtime-generate-lock; do \
187 ## Succeed if and only if the first process succeeded; exit this
188 ## process returning the status of the generated stamp.
190 test -f $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp; \
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.
200 ## Call SWIG to generate the various output files; special
201 ## post-processing on 'mingw32' host OS for the dependency file.
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; \
214 $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.S*; exit 1; \
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
224 ## (1) remove the current dependency file
226 $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.d
228 ## (2) Copy the whole SWIG file:
230 cp $(DEPDIR)/gnuradio_swig_py_runtime.Std $(DEPDIR)/gnuradio_swig_py_runtime.d
232 ## (3) all a carriage return to the end of the dependency file.
234 echo "" >> $(DEPDIR)/gnuradio_swig_py_runtime.d
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.
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
244 ## (5) remove the SWIG-generated file
246 $(RM) $(DEPDIR)/gnuradio_swig_py_runtime.Std
248 ## Create the stamp for this filename generation, to signal success in
249 ## executing this rule; allows other threads waiting on this process
252 touch $(DEPDIR)/gnuradio_swig_py_runtime-generate-stamp
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.
258 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_runtime.d@am__quote@
262 # Copyright 2009 Free Software Foundation, Inc.
264 # This file is part of GNU Radio
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)
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.
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.
282 # Makefile.swig.gen for gnuradio_swig_py_general.i
284 ## Default install locations for these files:
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
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.
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)
300 ## SWIG headers are always installed into the same directory.
302 gnuradio_swig_py_general_swigincludedir = $(swigincludedir)
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).
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 >
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.
324 STAMPS += $(DEPDIR)/gnuradio_swig_py_general-generate-*
326 ## Other cleaned files: dependency files generated by SWIG or this Makefile
328 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
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 .
334 swig_built_sources += gnuradio_swig_py_general.py gnuradio_swig_py_general.cc
336 ## Various SWIG variables. These can be overloaded in the including
337 ## Makefile.am by setting the variable value there, then including
340 gnuradio_swig_py_general_swiginclude_HEADERS = \
341 gnuradio_swig_py_general.i \
342 $(gnuradio_swig_py_general_swiginclude_headers)
344 gnuradio_swig_py_general_pylib_LTLIBRARIES = \
345 _gnuradio_swig_py_general.la
347 _gnuradio_swig_py_general_la_SOURCES = \
348 gnuradio_swig_py_general.cc \
349 $(gnuradio_swig_py_general_la_swig_sources)
351 _gnuradio_swig_py_general_la_LIBADD = \
352 $(STD_SWIG_LA_LIB_ADD) \
353 $(gnuradio_swig_py_general_la_swig_libadd)
355 _gnuradio_swig_py_general_la_LDFLAGS = \
356 $(STD_SWIG_LA_LD_FLAGS) \
357 $(gnuradio_swig_py_general_la_swig_ldflags)
359 _gnuradio_swig_py_general_la_CXXFLAGS = \
360 $(STD_SWIG_CXX_FLAGS) \
361 $(gnuradio_swig_py_general_la_swig_cxxflags)
363 gnuradio_swig_py_general_python_PYTHON = \
364 gnuradio_swig_py_general.py \
365 $(gnuradio_swig_py_general_python)
367 ## Entry rule for running SWIG
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:
373 ## * The .i file is newer than any or all of the generated files;
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
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:
386 ## if test -f $@; then :; else
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.
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.
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.
407 trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_general-generate-*' 1 2 13 15; \
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.
414 if mkdir $(DEPDIR)/gnuradio_swig_py_general-generate-lock 2>/dev/null; then \
416 ## This code is being executed by the first process to succeed in
417 ## creating the directory lock.
419 ## Remove the stamp associated with this filename.
421 rm -f $(DEPDIR)/gnuradio_swig_py_general-generate-stamp; \
423 ## Tell MAKE to run the rule for creating this stamp.
425 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_general-generate-stamp WHAT=$<; \
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.
434 rmdir $(DEPDIR)/gnuradio_swig_py_general-generate-lock; \
437 ## This code is being executed by any follower processes while the
438 ## directory lock is in place.
440 ## Wait until the first process is done, testing once per second.
442 while test -d $(DEPDIR)/gnuradio_swig_py_general-generate-lock; do \
446 ## Succeed if and only if the first process succeeded; exit this
447 ## process returning the status of the generated stamp.
449 test -f $(DEPDIR)/gnuradio_swig_py_general-generate-stamp; \
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.
459 ## Call SWIG to generate the various output files; special
460 ## post-processing on 'mingw32' host OS for the dependency file.
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; \
473 $(RM) $(DEPDIR)/gnuradio_swig_py_general.S*; exit 1; \
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
483 ## (1) remove the current dependency file
485 $(RM) $(DEPDIR)/gnuradio_swig_py_general.d
487 ## (2) Copy the whole SWIG file:
489 cp $(DEPDIR)/gnuradio_swig_py_general.Std $(DEPDIR)/gnuradio_swig_py_general.d
491 ## (3) all a carriage return to the end of the dependency file.
493 echo "" >> $(DEPDIR)/gnuradio_swig_py_general.d
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.
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
503 ## (5) remove the SWIG-generated file
505 $(RM) $(DEPDIR)/gnuradio_swig_py_general.Std
507 ## Create the stamp for this filename generation, to signal success in
508 ## executing this rule; allows other threads waiting on this process
511 touch $(DEPDIR)/gnuradio_swig_py_general-generate-stamp
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.
517 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_general.d@am__quote@
521 # Copyright 2009 Free Software Foundation, Inc.
523 # This file is part of GNU Radio
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)
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.
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.
541 # Makefile.swig.gen for gnuradio_swig_py_gengen.i
543 ## Default install locations for these files:
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
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.
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)
559 ## SWIG headers are always installed into the same directory.
561 gnuradio_swig_py_gengen_swigincludedir = $(swigincludedir)
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).
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 >
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.
583 STAMPS += $(DEPDIR)/gnuradio_swig_py_gengen-generate-*
585 ## Other cleaned files: dependency files generated by SWIG or this Makefile
587 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
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 .
593 swig_built_sources += gnuradio_swig_py_gengen.py gnuradio_swig_py_gengen.cc
595 ## Various SWIG variables. These can be overloaded in the including
596 ## Makefile.am by setting the variable value there, then including
599 gnuradio_swig_py_gengen_swiginclude_HEADERS = \
600 gnuradio_swig_py_gengen.i \
601 $(gnuradio_swig_py_gengen_swiginclude_headers)
603 gnuradio_swig_py_gengen_pylib_LTLIBRARIES = \
604 _gnuradio_swig_py_gengen.la
606 _gnuradio_swig_py_gengen_la_SOURCES = \
607 gnuradio_swig_py_gengen.cc \
608 $(gnuradio_swig_py_gengen_la_swig_sources)
610 _gnuradio_swig_py_gengen_la_LIBADD = \
611 $(STD_SWIG_LA_LIB_ADD) \
612 $(gnuradio_swig_py_gengen_la_swig_libadd)
614 _gnuradio_swig_py_gengen_la_LDFLAGS = \
615 $(STD_SWIG_LA_LD_FLAGS) \
616 $(gnuradio_swig_py_gengen_la_swig_ldflags)
618 _gnuradio_swig_py_gengen_la_CXXFLAGS = \
619 $(STD_SWIG_CXX_FLAGS) \
620 $(gnuradio_swig_py_gengen_la_swig_cxxflags)
622 gnuradio_swig_py_gengen_python_PYTHON = \
623 gnuradio_swig_py_gengen.py \
624 $(gnuradio_swig_py_gengen_python)
626 ## Entry rule for running SWIG
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:
632 ## * The .i file is newer than any or all of the generated files;
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
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:
645 ## if test -f $@; then :; else
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.
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.
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.
666 trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_gengen-generate-*' 1 2 13 15; \
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.
673 if mkdir $(DEPDIR)/gnuradio_swig_py_gengen-generate-lock 2>/dev/null; then \
675 ## This code is being executed by the first process to succeed in
676 ## creating the directory lock.
678 ## Remove the stamp associated with this filename.
680 rm -f $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp; \
682 ## Tell MAKE to run the rule for creating this stamp.
684 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp WHAT=$<; \
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.
693 rmdir $(DEPDIR)/gnuradio_swig_py_gengen-generate-lock; \
696 ## This code is being executed by any follower processes while the
697 ## directory lock is in place.
699 ## Wait until the first process is done, testing once per second.
701 while test -d $(DEPDIR)/gnuradio_swig_py_gengen-generate-lock; do \
705 ## Succeed if and only if the first process succeeded; exit this
706 ## process returning the status of the generated stamp.
708 test -f $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp; \
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.
718 ## Call SWIG to generate the various output files; special
719 ## post-processing on 'mingw32' host OS for the dependency file.
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; \
732 $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.S*; exit 1; \
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
742 ## (1) remove the current dependency file
744 $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.d
746 ## (2) Copy the whole SWIG file:
748 cp $(DEPDIR)/gnuradio_swig_py_gengen.Std $(DEPDIR)/gnuradio_swig_py_gengen.d
750 ## (3) all a carriage return to the end of the dependency file.
752 echo "" >> $(DEPDIR)/gnuradio_swig_py_gengen.d
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.
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
762 ## (5) remove the SWIG-generated file
764 $(RM) $(DEPDIR)/gnuradio_swig_py_gengen.Std
766 ## Create the stamp for this filename generation, to signal success in
767 ## executing this rule; allows other threads waiting on this process
770 touch $(DEPDIR)/gnuradio_swig_py_gengen-generate-stamp
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.
776 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_gengen.d@am__quote@
780 # Copyright 2009 Free Software Foundation, Inc.
782 # This file is part of GNU Radio
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)
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.
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.
800 # Makefile.swig.gen for gnuradio_swig_py_filter.i
802 ## Default install locations for these files:
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
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.
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)
818 ## SWIG headers are always installed into the same directory.
820 gnuradio_swig_py_filter_swigincludedir = $(swigincludedir)
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).
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 >
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.
842 STAMPS += $(DEPDIR)/gnuradio_swig_py_filter-generate-*
844 ## Other cleaned files: dependency files generated by SWIG or this Makefile
846 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
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 .
852 swig_built_sources += gnuradio_swig_py_filter.py gnuradio_swig_py_filter.cc
854 ## Various SWIG variables. These can be overloaded in the including
855 ## Makefile.am by setting the variable value there, then including
858 gnuradio_swig_py_filter_swiginclude_HEADERS = \
859 gnuradio_swig_py_filter.i \
860 $(gnuradio_swig_py_filter_swiginclude_headers)
862 gnuradio_swig_py_filter_pylib_LTLIBRARIES = \
863 _gnuradio_swig_py_filter.la
865 _gnuradio_swig_py_filter_la_SOURCES = \
866 gnuradio_swig_py_filter.cc \
867 $(gnuradio_swig_py_filter_la_swig_sources)
869 _gnuradio_swig_py_filter_la_LIBADD = \
870 $(STD_SWIG_LA_LIB_ADD) \
871 $(gnuradio_swig_py_filter_la_swig_libadd)
873 _gnuradio_swig_py_filter_la_LDFLAGS = \
874 $(STD_SWIG_LA_LD_FLAGS) \
875 $(gnuradio_swig_py_filter_la_swig_ldflags)
877 _gnuradio_swig_py_filter_la_CXXFLAGS = \
878 $(STD_SWIG_CXX_FLAGS) \
879 $(gnuradio_swig_py_filter_la_swig_cxxflags)
881 gnuradio_swig_py_filter_python_PYTHON = \
882 gnuradio_swig_py_filter.py \
883 $(gnuradio_swig_py_filter_python)
885 ## Entry rule for running SWIG
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:
891 ## * The .i file is newer than any or all of the generated files;
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
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:
904 ## if test -f $@; then :; else
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.
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.
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.
925 trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_filter-generate-*' 1 2 13 15; \
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.
932 if mkdir $(DEPDIR)/gnuradio_swig_py_filter-generate-lock 2>/dev/null; then \
934 ## This code is being executed by the first process to succeed in
935 ## creating the directory lock.
937 ## Remove the stamp associated with this filename.
939 rm -f $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp; \
941 ## Tell MAKE to run the rule for creating this stamp.
943 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp WHAT=$<; \
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.
952 rmdir $(DEPDIR)/gnuradio_swig_py_filter-generate-lock; \
955 ## This code is being executed by any follower processes while the
956 ## directory lock is in place.
958 ## Wait until the first process is done, testing once per second.
960 while test -d $(DEPDIR)/gnuradio_swig_py_filter-generate-lock; do \
964 ## Succeed if and only if the first process succeeded; exit this
965 ## process returning the status of the generated stamp.
967 test -f $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp; \
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.
977 ## Call SWIG to generate the various output files; special
978 ## post-processing on 'mingw32' host OS for the dependency file.
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; \
991 $(RM) $(DEPDIR)/gnuradio_swig_py_filter.S*; exit 1; \
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
1001 ## (1) remove the current dependency file
1003 $(RM) $(DEPDIR)/gnuradio_swig_py_filter.d
1005 ## (2) Copy the whole SWIG file:
1007 cp $(DEPDIR)/gnuradio_swig_py_filter.Std $(DEPDIR)/gnuradio_swig_py_filter.d
1009 ## (3) all a carriage return to the end of the dependency file.
1011 echo "" >> $(DEPDIR)/gnuradio_swig_py_filter.d
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.
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
1021 ## (5) remove the SWIG-generated file
1023 $(RM) $(DEPDIR)/gnuradio_swig_py_filter.Std
1025 ## Create the stamp for this filename generation, to signal success in
1026 ## executing this rule; allows other threads waiting on this process
1029 touch $(DEPDIR)/gnuradio_swig_py_filter-generate-stamp
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.
1035 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_filter.d@am__quote@
1039 # Copyright 2009 Free Software Foundation, Inc.
1041 # This file is part of GNU Radio
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.
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.
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.
1059 # Makefile.swig.gen for gnuradio_swig_py_io.i
1061 ## Default install locations for these files:
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
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.
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)
1077 ## SWIG headers are always installed into the same directory.
1079 gnuradio_swig_py_io_swigincludedir = $(swigincludedir)
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).
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 >
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.
1101 STAMPS += $(DEPDIR)/gnuradio_swig_py_io-generate-*
1103 ## Other cleaned files: dependency files generated by SWIG or this Makefile
1105 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
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 .
1111 swig_built_sources += gnuradio_swig_py_io.py gnuradio_swig_py_io.cc
1113 ## Various SWIG variables. These can be overloaded in the including
1114 ## Makefile.am by setting the variable value there, then including
1117 gnuradio_swig_py_io_swiginclude_HEADERS = \
1118 gnuradio_swig_py_io.i \
1119 $(gnuradio_swig_py_io_swiginclude_headers)
1121 gnuradio_swig_py_io_pylib_LTLIBRARIES = \
1122 _gnuradio_swig_py_io.la
1124 _gnuradio_swig_py_io_la_SOURCES = \
1125 gnuradio_swig_py_io.cc \
1126 $(gnuradio_swig_py_io_la_swig_sources)
1128 _gnuradio_swig_py_io_la_LIBADD = \
1129 $(STD_SWIG_LA_LIB_ADD) \
1130 $(gnuradio_swig_py_io_la_swig_libadd)
1132 _gnuradio_swig_py_io_la_LDFLAGS = \
1133 $(STD_SWIG_LA_LD_FLAGS) \
1134 $(gnuradio_swig_py_io_la_swig_ldflags)
1136 _gnuradio_swig_py_io_la_CXXFLAGS = \
1137 $(STD_SWIG_CXX_FLAGS) \
1138 $(gnuradio_swig_py_io_la_swig_cxxflags)
1140 gnuradio_swig_py_io_python_PYTHON = \
1141 gnuradio_swig_py_io.py \
1142 $(gnuradio_swig_py_io_python)
1144 ## Entry rule for running SWIG
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:
1150 ## * The .i file is newer than any or all of the generated files;
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
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:
1163 ## if test -f $@; then :; else
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.
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.
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.
1184 trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_io-generate-*' 1 2 13 15; \
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.
1191 if mkdir $(DEPDIR)/gnuradio_swig_py_io-generate-lock 2>/dev/null; then \
1193 ## This code is being executed by the first process to succeed in
1194 ## creating the directory lock.
1196 ## Remove the stamp associated with this filename.
1198 rm -f $(DEPDIR)/gnuradio_swig_py_io-generate-stamp; \
1200 ## Tell MAKE to run the rule for creating this stamp.
1202 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_io-generate-stamp WHAT=$<; \
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.
1211 rmdir $(DEPDIR)/gnuradio_swig_py_io-generate-lock; \
1214 ## This code is being executed by any follower processes while the
1215 ## directory lock is in place.
1217 ## Wait until the first process is done, testing once per second.
1219 while test -d $(DEPDIR)/gnuradio_swig_py_io-generate-lock; do \
1223 ## Succeed if and only if the first process succeeded; exit this
1224 ## process returning the status of the generated stamp.
1226 test -f $(DEPDIR)/gnuradio_swig_py_io-generate-stamp; \
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.
1236 ## Call SWIG to generate the various output files; special
1237 ## post-processing on 'mingw32' host OS for the dependency file.
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; \
1250 $(RM) $(DEPDIR)/gnuradio_swig_py_io.S*; exit 1; \
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
1260 ## (1) remove the current dependency file
1262 $(RM) $(DEPDIR)/gnuradio_swig_py_io.d
1264 ## (2) Copy the whole SWIG file:
1266 cp $(DEPDIR)/gnuradio_swig_py_io.Std $(DEPDIR)/gnuradio_swig_py_io.d
1268 ## (3) all a carriage return to the end of the dependency file.
1270 echo "" >> $(DEPDIR)/gnuradio_swig_py_io.d
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.
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
1280 ## (5) remove the SWIG-generated file
1282 $(RM) $(DEPDIR)/gnuradio_swig_py_io.Std
1284 ## Create the stamp for this filename generation, to signal success in
1285 ## executing this rule; allows other threads waiting on this process
1288 touch $(DEPDIR)/gnuradio_swig_py_io-generate-stamp
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.
1294 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_io.d@am__quote@
1298 # Copyright 2009 Free Software Foundation, Inc.
1300 # This file is part of GNU Radio
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.
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.
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.
1318 # Makefile.swig.gen for gnuradio_swig_py_hier.i
1320 ## Default install locations for these files:
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
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.
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)
1336 ## SWIG headers are always installed into the same directory.
1338 gnuradio_swig_py_hier_swigincludedir = $(swigincludedir)
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).
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 >
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.
1360 STAMPS += $(DEPDIR)/gnuradio_swig_py_hier-generate-*
1362 ## Other cleaned files: dependency files generated by SWIG or this Makefile
1364 MOSTLYCLEANFILES += $(DEPDIR)/*.S*
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 .
1370 swig_built_sources += gnuradio_swig_py_hier.py gnuradio_swig_py_hier.cc
1372 ## Various SWIG variables. These can be overloaded in the including
1373 ## Makefile.am by setting the variable value there, then including
1376 gnuradio_swig_py_hier_swiginclude_HEADERS = \
1377 gnuradio_swig_py_hier.i \
1378 $(gnuradio_swig_py_hier_swiginclude_headers)
1380 gnuradio_swig_py_hier_pylib_LTLIBRARIES = \
1381 _gnuradio_swig_py_hier.la
1383 _gnuradio_swig_py_hier_la_SOURCES = \
1384 gnuradio_swig_py_hier.cc \
1385 $(gnuradio_swig_py_hier_la_swig_sources)
1387 _gnuradio_swig_py_hier_la_LIBADD = \
1388 $(STD_SWIG_LA_LIB_ADD) \
1389 $(gnuradio_swig_py_hier_la_swig_libadd)
1391 _gnuradio_swig_py_hier_la_LDFLAGS = \
1392 $(STD_SWIG_LA_LD_FLAGS) \
1393 $(gnuradio_swig_py_hier_la_swig_ldflags)
1395 _gnuradio_swig_py_hier_la_CXXFLAGS = \
1396 $(STD_SWIG_CXX_FLAGS) \
1397 $(gnuradio_swig_py_hier_la_swig_cxxflags)
1399 gnuradio_swig_py_hier_python_PYTHON = \
1400 gnuradio_swig_py_hier.py \
1401 $(gnuradio_swig_py_hier_python)
1403 ## Entry rule for running SWIG
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:
1409 ## * The .i file is newer than any or all of the generated files;
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
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:
1422 ## if test -f $@; then :; else
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.
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.
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.
1443 trap 'rm -rf $(DEPDIR)/gnuradio_swig_py_hier-generate-*' 1 2 13 15; \
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.
1450 if mkdir $(DEPDIR)/gnuradio_swig_py_hier-generate-lock 2>/dev/null; then \
1452 ## This code is being executed by the first process to succeed in
1453 ## creating the directory lock.
1455 ## Remove the stamp associated with this filename.
1457 rm -f $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp; \
1459 ## Tell MAKE to run the rule for creating this stamp.
1461 $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp WHAT=$<; \
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.
1470 rmdir $(DEPDIR)/gnuradio_swig_py_hier-generate-lock; \
1473 ## This code is being executed by any follower processes while the
1474 ## directory lock is in place.
1476 ## Wait until the first process is done, testing once per second.
1478 while test -d $(DEPDIR)/gnuradio_swig_py_hier-generate-lock; do \
1482 ## Succeed if and only if the first process succeeded; exit this
1483 ## process returning the status of the generated stamp.
1485 test -f $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp; \
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.
1495 ## Call SWIG to generate the various output files; special
1496 ## post-processing on 'mingw32' host OS for the dependency file.
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; \
1509 $(RM) $(DEPDIR)/gnuradio_swig_py_hier.S*; exit 1; \
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
1519 ## (1) remove the current dependency file
1521 $(RM) $(DEPDIR)/gnuradio_swig_py_hier.d
1523 ## (2) Copy the whole SWIG file:
1525 cp $(DEPDIR)/gnuradio_swig_py_hier.Std $(DEPDIR)/gnuradio_swig_py_hier.d
1527 ## (3) all a carriage return to the end of the dependency file.
1529 echo "" >> $(DEPDIR)/gnuradio_swig_py_hier.d
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.
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
1539 ## (5) remove the SWIG-generated file
1541 $(RM) $(DEPDIR)/gnuradio_swig_py_hier.Std
1543 ## Create the stamp for this filename generation, to signal success in
1544 ## executing this rule; allows other threads waiting on this process
1547 touch $(DEPDIR)/gnuradio_swig_py_hier-generate-stamp
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.
1553 @am__include@ @am__quote@./$(DEPDIR)/gnuradio_swig_py_hier.d@am__quote@