diff options
author | manojgudi | 2013-10-07 14:04:07 +0530 |
---|---|---|
committer | manojgudi | 2013-10-07 14:04:07 +0530 |
commit | e9576e44ef8f0ad67d8cd8a4e025a0f8da0727f8 (patch) | |
tree | 3a77657667b4ef037f712ee68a5ec86c86cba5c5 /gr-scigen/python/__init__.py | |
parent | ed97c528ce61496e10d612a4f5e9aef509b65ccf (diff) | |
download | gnuradio-e9576e44ef8f0ad67d8cd8a4e025a0f8da0727f8.tar.gz gnuradio-e9576e44ef8f0ad67d8cd8a4e025a0f8da0727f8.tar.bz2 gnuradio-e9576e44ef8f0ad67d8cd8a4e025a0f8da0727f8.zip |
added gr-scimod block+CMake change | compiles fine
Diffstat (limited to 'gr-scigen/python/__init__.py')
-rw-r--r-- | gr-scigen/python/__init__.py | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/gr-scigen/python/__init__.py b/gr-scigen/python/__init__.py new file mode 100644 index 000000000..11a291ae4 --- /dev/null +++ b/gr-scigen/python/__init__.py @@ -0,0 +1,52 @@ +# +# Copyright 2008,2009 Free Software Foundation, Inc. +# +# This application is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3, or (at your option) +# any later version. +# +# This application is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program; if not, write to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +# + +# The presence of this file turns this directory into a Python package + +''' +This is the GNU Radio SCIGEN module. Place your Python package +description here (python/__init__.py). +''' + +# ---------------------------------------------------------------- +# Temporary workaround for ticket:181 (swig+python problem) +import sys +_RTLD_GLOBAL = 0 +try: + from dl import RTLD_GLOBAL as _RTLD_GLOBAL +except ImportError: + try: + from DLFCN import RTLD_GLOBAL as _RTLD_GLOBAL + except ImportError: + pass + +if _RTLD_GLOBAL != 0: + _dlopenflags = sys.getdlopenflags() + sys.setdlopenflags(_dlopenflags|_RTLD_GLOBAL) +# ---------------------------------------------------------------- + + +# import any pure python here +from generic import * +# + +# ---------------------------------------------------------------- +# Tail of workaround +if _RTLD_GLOBAL != 0: + sys.setdlopenflags(_dlopenflags) # Restore original flags +# ---------------------------------------------------------------- |