summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosh Blum2011-04-26 22:59:13 -0700
committerJosh Blum2011-04-26 22:59:13 -0700
commit42783746a78bf4d094e6ff9b6971b565e9ac59dd (patch)
tree627f63f87b97c9e48d2a325919eb7f80b1e6c8fd
parenta5e2d9e5baf869ae961fbb5820447290d6d9c7c8 (diff)
downloadgnuradio-42783746a78bf4d094e6ff9b6971b565e9ac59dd.tar.gz
gnuradio-42783746a78bf4d094e6ff9b6971b565e9ac59dd.tar.bz2
gnuradio-42783746a78bf4d094e6ff9b6971b565e9ac59dd.zip
gnuradio: support out-of-tree bootstrap
Run bootstrap from any directory and it will work. The bootstrap script determines the source directory, and cds into that directory to run each auto* command. The bootstrap files also print that they are run, and there is a place to add-in future sub-projects.
-rwxr-xr-xbootstrap24
-rwxr-xr-xusrp2/firmware/bootstrap16
-rwxr-xr-xvolk/bootstrap23
3 files changed, 37 insertions, 26 deletions
diff --git a/bootstrap b/bootstrap
index be511806f..341f157f9 100755
--- a/bootstrap
+++ b/bootstrap
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2001,2005,2008 Free Software Foundation, Inc.
+# Copyright 2001-2011 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -19,16 +19,20 @@
# the Free Software Foundation, Inc., 51 Franklin Street,
# Boston, MA 02110-1301, USA.
+srcdir=$(cd $(dirname $0) ; pwd)
-rm -fr config.cache autom4te*.cache
+echo "Bootstrap'n gnuradio... ${srcdir}"
-aclocal -I config
-autoconf
-autoheader
-libtoolize --automake
-automake --add-missing -Wno-portability -Wno-override -Wnone
-#automake --add-missing -Wno-portability
+(cd ${srcdir} ; rm -fr config.cache autom4te*.cache)
+(cd ${srcdir} ; autoconf)
+(cd ${srcdir} ; autoheader)
+(cd ${srcdir} ; libtoolize --automake)
+(cd ${srcdir} ; automake --add-missing -Wno-portability -Wno-override -Wnone)
# Run bootstrap in any subprojects
-(cd usrp2/firmware ; ./bootstrap)
-(cd volk ; ./bootstrap)
+subprojects="usrp2/firmware
+volk"
+for dir in ${subprojects}; do
+ (mkdir -p ${dir}) #ensure the build dir exists
+ (cd ${dir} ; sh ${srcdir}/${dir}/bootstrap)
+done
diff --git a/usrp2/firmware/bootstrap b/usrp2/firmware/bootstrap
index 4106d4746..a72eced6b 100755
--- a/usrp2/firmware/bootstrap
+++ b/usrp2/firmware/bootstrap
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2001,2005 Free Software Foundation, Inc.
+# Copyright 2001-2011 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -19,12 +19,14 @@
# the Free Software Foundation, Inc., 51 Franklin Street,
# Boston, MA 02110-1301, USA.
+srcdir=$(cd $(dirname $0) ; pwd)
-rm -fr config.cache autom4te*.cache
+echo "Bootstrap'n usrp2 firmware... ${srcdir}"
-aclocal -I config
-autoconf
-autoheader
-# libtoolize --automake
-automake --add-missing -Wno-portability
+(cd ${srcdir} ; rm -fr config.cache autom4te*.cache)
+(cd ${srcdir} ; aclocal -I config)
+(cd ${srcdir} ; autoconf)
+(cd ${srcdir} ; autoheader)
+# (cd ${srcdir} ; libtoolize --automake)
+(cd ${srcdir} ; automake --add-missing -Wno-portability)
diff --git a/volk/bootstrap b/volk/bootstrap
index a7fb78ac5..b11506750 100755
--- a/volk/bootstrap
+++ b/volk/bootstrap
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2001,2005,2008 Free Software Foundation, Inc.
+# Copyright 2001-2011 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -18,14 +18,19 @@
# along with GNU Radio; see the file COPYING. If not, write to
# the Free Software Foundation, Inc., 51 Franklin Street,
# Boston, MA 02110-1301, USA.
-rm -fr config.cache autom4te*.cache
-python -B gen/volk_register.py
-mv gen/lib/Makefile.am lib/
+srcdir=$(cd $(dirname $0) ; pwd)
+gendir=${srcdir}/gen
-aclocal -I config -I gen/config
-autoconf
-autoheader
-libtoolize --automake
-automake --add-missing -Wno-portability -Wno-override -Wnone
+echo "Bootstrap'n volk... ${srcdir}"
+
+python -B ${srcdir}/gen/volk_register.py
+mv ${gendir}/lib/Makefile.am ${srcdir}/lib/
+
+(cd ${srcdir} ; rm -fr config.cache autom4te*.cache)
+(cd ${srcdir} ; aclocal -I config -I ${gendir}/config)
+(cd ${srcdir} ; autoconf)
+(cd ${srcdir} ; autoheader)
+(cd ${srcdir} ; libtoolize --automake)
+(cd ${srcdir} ; automake --add-missing -Wno-portability -Wno-override -Wnone)