#----------------------------------------------------------------------
# Some SCONS shortcuts
#----------------------------------------------------------------------
-SCONS=scons
+
+CONCURRENCY_LEVEL ?= 1
+
+SCONS=scons -j $(CONCURRENCY_LEVEL)
default: build
clean:
$(SCONS) --clean all
-all_docs all_tests:
+all_docs all_tests all:
$(SCONS) $@
#----------------------------------------------------------------------
# Subversion stuff
#----------------------------------------------------------------------
-SVN_REVISION = $(shell svnversion)
svn_version:
- @echo $(SVN_REVISION)
+ @svnversion
#----------------------------------------------------------------------
# Building SENF requires some debian packages
#----------------------------------------------------------------------
-DEB_BASE = scons build-essential binutils-dev
-DEB_BOOST = libboost-dev libboost-test-dev
-DEB_BOOST += libboost-date-time-dev libboost-regex-dev libboost-thread-dev
-DEB_DOC = doxygen dia tidy xsltproc graphviz
+DEB_BASE = build-essential
+
+# This line parses the 'Build-Depends' entry from debian/control
+DEB_SENF = $(shell perl -an -F'[:,]' -e ' \
+ BEGIN{ $$,=" " } \
+ $$P=0 if /^\S/; \
+ map {s/\(.*\)//} @F; \
+ print @F if $$P; \
+ if (/^Build-Depends:/) { print @F[1..$$\#F]; $$P=1 }' \
+ debian/control | xargs echo)
prerequisites:
- aptitude install $(DEB_BASE) $(DEB_BOOST) $(DEB_DOC)
+ aptitude install $(DEB_BASE) $(DEB_SENF)
package:
$(SCONS) deb
else:
rev = 'r' + os.popen("svnversion").read().strip().lower()
+logname = os.environ.get('LOGNAME')
+if not logname:
+ logname = pwd.getpwuid(os.getuid()).pw_name
+
env.Append(
CPPPATH = [ '#' ],
LIBS = [ 'iberty', '$BOOSTREGEXLIB' ],
DOXY_HTML_XSL = '#/doclib/html-munge.xsl',
ENV = { 'TODAY' : str(datetime.date.today()),
'REVISION' : rev,
- 'LOGNAME' : os.environ['LOGNAME'], # needed by the debian build scripts
+ 'LOGNAME' : logname, # needed by the debian build scripts
'CONCURRENCY_LEVEL' : env.GetOption('num_jobs') or "1"
},
)
Source: libsenf
Priority: extra
Maintainer: Stefan Bund <senf-dev@lists.berlios.de>
-Build-Depends: debhelper (>= 5), scons, libboost-dev, libboost-test-dev, libboost-date-time-dev, libboost-regex-dev, libboost-thread-dev, doxygen, dia, tidy, xsltproc, graphviz
+Build-Depends: debhelper (>= 5), scons, binutils-dev, libboost-dev,
+ libboost-test-dev, libboost-date-time-dev, libboost-regex-dev,
+ libboost-thread-dev, doxygen, dia, tidy, xsltproc, graphviz
Standards-Version: 3.7.2
Section: libs
Package: libsenf-dev
Section: libdevel
Architecture: any
-Depends: binutils-dev, libboost-dev, libboost-regex-dev, libboost-date-time-dev, libboost-thread-dev
+Depends: binutils-dev, libboost-dev, libboost-regex-dev,
+ libboost-date-time-dev, libboost-thread-dev
Description: SENF Extensible Network Framework, development files
The SENF Simple and Extensible Network Framework aims to be a
complete set of libraries to facilitate the development of network