summaryrefslogtreecommitdiff
path: root/volk/config/gcc_version_workaround.m4
diff options
context:
space:
mode:
authorJohnathan Corgan2011-03-16 08:18:30 -0700
committerJohnathan Corgan2011-03-16 08:18:30 -0700
commit4cd06fadac972d4cac559c15488bc39823063afe (patch)
tree6fe57896bc216d8c9e672194f2e4e0e75aedb645 /volk/config/gcc_version_workaround.m4
parent4ad736e21f45f64fd616bb53f54e45e1c63e7330 (diff)
parent1d70ed2bd928d52a383e688949cc7f747dd584fa (diff)
downloadgnuradio-4cd06fadac972d4cac559c15488bc39823063afe.tar.gz
gnuradio-4cd06fadac972d4cac559c15488bc39823063afe.tar.bz2
gnuradio-4cd06fadac972d4cac559c15488bc39823063afe.zip
Merge remote branch 'gnuradio/next'
* gnuradio/next: (806 commits) gruel: added missing ignores gruel: fixed swig interface file to dereference pmt_t. qtgui: fix distcheck error gruel: fixing structure. Passes make check. gruel: SWIGing Gruel into Python to access PMTs. gnuradio-examples: add C++ audio examples using new gr-audio created gruel/attributes.h to house compiler specific attribute macros audio: remove obsoleted individual top-level components gr-audio: added README and default config fix volk: simplify the get new method for the aligned pool grc: moved all usrp1 and usrp2 stuff out of grc and into gr-usrp*/grc grc: swap store the subprocess object rather than the pid when executing qtgui: removed python directory that was added, never used uhd: use %ignore to hide warnings and fix errors Added/updated ignore files. Fixing gr_filter_design program to import from gnuradio Python package. audio: high prio for platform specific audio osx audio: added windows and osx audio source files audio: added config checks for other audios, added jack and port audio: make prefs look like old audio, removed old audio.py ...
Diffstat (limited to 'volk/config/gcc_version_workaround.m4')
-rwxr-xr-xvolk/config/gcc_version_workaround.m453
1 files changed, 53 insertions, 0 deletions
diff --git a/volk/config/gcc_version_workaround.m4 b/volk/config/gcc_version_workaround.m4
new file mode 100755
index 000000000..3cd8a0cc7
--- /dev/null
+++ b/volk/config/gcc_version_workaround.m4
@@ -0,0 +1,53 @@
+AC_DEFUN([LV_GCC_VERSION_WORKAROUND],
+[
+ case "${host_os}" in
+ *cygwin*)
+ ;;
+ *)
+ AC_REQUIRE([LF_CONFIGURE_CXX])
+
+ cxx_version=`$CXX --version`
+
+ cxx_major_version=`echo $cxx_version | sed 's/[[^)]]*) \([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\).*/\1/'`
+ cxx_minor_version=`echo $cxx_version | sed 's/g++ [[^)]]*) \([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\).*/\2/'`
+ cxx_micro_version=`echo $cxx_version | sed 's/g++ [[^)]]*) \([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\).*/\3/'`
+
+ if test ["$cxx_minor_version" -lt "3"] -o ["$cxx_major_version" -lt "4"]; then
+ cxx_proper_version="$cxx_major_version.$cxx_minor_version.$cxx_micro_version"
+
+
+ my_arch=`uname -m`
+
+ if test "${my_arch}" = i686; then
+ my_arch="${my_arch} i586 i486 i386"
+ fi
+ if test "${my_arch}" = i586; then
+ my_arch = "${my_arch} i686 i386 i486"
+ fi
+ if test "${my_arch}" = i486; then
+ my_arch = "${my_arch} i686 i386 i586"
+ fi
+ if test "${my_arch}" = i386; then
+ my_arch = "${my_arch} i686 i586 i486"
+ fi
+
+ for i in $my_arch
+ do
+ if test -n "`ls /usr/include/c++/$cxx_proper_version | grep $i`"; then
+ mystery_dir=`ls /usr/include/c++/$cxx_proper_version | grep $i`
+ echo `ls /usr/include/c++/$cxx_proper_version | grep $i`
+ fi
+ done
+ echo "${mystery_dir}"
+
+ LV_CXXFLAGS="${LV_CXXFLAGS} -nostdinc++ -I/usr/include/c++/$cxx_proper_version -I/usr/include/c++/$cxx_proper_version/$mystery_dir"
+
+ CXXFLAGS="${CXXFLAGS} -nostdinc++ -I/usr/include/c++/$cxx_proper_version -I/usr/include/c++/$cxx_proper_version/$mystery_dir"
+
+
+
+ fi
+
+ esac
+
+ ]) \ No newline at end of file