- extensible design
- concise interface
+
-- Stefan Bund <senf-dev@lists.berlios.de> Tue, 28 Aug 2007 10:02:23 +0200
import sys, glob, os.path, fnmatch
import SENFSCons, senfutil
+# Fix for SCons 0.97 compatibility
try:
BoolVariable
except NameError:
# Load all the local SCons tools
env.Tool('Doxygen')
+env.Tool('Doxygen')
env.Tool('Dia2Png')
env.Tool('PkgDraw')
env.Tool('InstallSubdir')
env.Append(
ENV = { 'PATH' : os.environ.get('PATH') },
- CLEAN_PATTERNS = [ '*~', '#*#', '*.pyc', 'semantic.cache', '.sconsign*', '.sconsign' ],
+ CLEAN_PATTERNS = [ '*~', '#*#', '*.pyc', 'semantic.cache', '.sconsign*' ],
CPPPATH = [ '#' ],
LOCALLIBDIR = '#',
LIBINSTALLDIR = '$PREFIX${syslayout and "/lib" or ""}',
BININSTALLDIR = '$PREFIX${syslayout and "/bin" or ""}',
INCLUDEINSTALLDIR = '$PREFIX${syslayout and "/include" or ""}',
- OBJINSTALLDIR = '${syslayout and "$LIBINSTALLDIR/senf" or "$PREFIX"}',
- DOCINSTALLDIR = '$PREFIX/manual',
- SCONSINSTALLDIR = '${syslayout and "$LIBINSTALLDIR/senf" or "$PREFIX"}/site_scons',
- CONFINSTALLDIR = '$OBJINSTALLDIR',
+ CONFINSTALLDIR = '${syslayout and "$LIBINSTALLDIR/senf" or "$PREFIX"}',
+ OBJINSTALLDIR = '$CONFINSTALLDIR',
+ DOCINSTALLDIR = '$PREFIX${syslayout and "/share/doc/senf" or "/manual"}',
+ SCONSINSTALLDIR = '$CONFINSTALLDIR/site_scons',
CPP_INCLUDE_EXTENSIONS = [ '.h', '.hh', '.ih', '.mpp', '.cci', '.ct', '.cti' ],
CPP_EXCLUDE_EXTENSIONS = [ '.test.hh' ],
env.Clean('all', '.prepare-stamp')
env.Clean('all', libsenf)
env.Clean('all', env.Dir('linklint')) # env.Dir to disambiguate from linklint PhonyTarget
+env.Clean('all', env.Dir('dist'))
if env.GetOption('clean'):
env.Clean('all', [ os.path.join(path,f)
/*.debhelper.log
/libsenf*/
/tmp/
+/*.substvars
Th SENF debian distribution consists of the following packages:
libsenf non-debug static library /usr/lib/libsenf.a
- /usr/lib/senf-packets/
+ /usr/lib/senf/*.o
libsenf-dbg debug static library /usr/lib/libsenf_g.a
- /usr/lib/debug/senf-packets/
+ /usr/lib/senf/*_g.o
libsenf-dev include files /usr/include/senf
+ /usr/lib/senf/site_scons
+ /usr/bin
- libsenf-doc documentation /usr/share/doc/libsenf-doc/
+ libsenf-doc documentation /usr/share/doc/libsenf-doc/html
+ /usr/share/doc/libsenf-doc/examples
So to develop using SENF, you will need 'libsenf-dev' and one of
both, 'libsenf' and 'libsenf-dbg'.
To compile an application against the debug library, just link against
-the libsenf_g.a library.
+the libsenf_g.a library AND ENSURE the preprocessor symbol
+'SENF_DEBUG' is defined.
To compile an application against the non-debug library, link against
-libsenf.a AND ENSURE, THE PREPROCESSOR SYMBOL 'SENF_NO_DEBUG' IS
-DEFINED in your build, best by adding '-DSENF_NO_DEBUG' to CPPFLAGS.
+libsenf.a.
Lets repeat that:
- VERY IMPORTANT: When building against libsenf.a, you MUST define
- SENF_NO_DEBUG. Don't say, you haven't been warned ...
+ VERY IMPORTANT: When building against libsenf_g.a, you MUST define
+ SENF_DEBUG. Don't say, you haven't been warned ...
env.Replace(
LOCAL_CONFIG_FILES = [ '/Doxyfile.local', '/SConscript.local', '/senf/local_config.hh' ],
- DPKG_IGNORED_FILES = [ '$LOCAL_CONFIG_FILES', '.svn', '/_templates' ],
+ DPKG_IGNORED_FILES = [ '$LOCAL_CONFIG_FILES', '.svn', '.git', '.gitignore', '/_templates',
+ '/TODO', '.project', '.cproject', '.dir.el', '/project.el' ],
DPKG_IGNORED_FILES_OPTS = dpkgIgnoredFilesOpts,
BUILDPACKAGE_COMMAND = "dpkg-buildpackage -us -uc -rfakeroot $DPKG_IGNORED_FILES_OPTS",
)
"fakeroot ./debian/rules debclean"
])
-env.Clean(env.Alias('all'), 'changelog')
+if not os.environ.get('debian_build'):
+ env.Clean(env.Alias('all'), '#/debian/changelog')
libboost-date-time-dev | libboost-date-time1.35-dev,
libboost-regex-dev | libboost-regex1.35-dev,
libboost-filesystem-dev | libboost-filesystem1.35-dev,
- libboost-serialization-dev | libboost-serialization1.35-dev,
libboost-iostreams-dev | libboost-iostreams1.35-dev,
libboost-signals-dev | libboost-signals1.35-dev,
doxygen (>= 1.5.5), libreadline-dev, dia, tidy, xsltproc, graphviz,
libboost-regex-dev | libboost-regex1.35-dev,
libboost-date-time-dev | libboost-date-time1.35-dev,
libboost-thread-dev | libboost-thread1.35-dev,
- libboost-serialization-dev | libboost-serialization1.35-dev,
libboost-filesystem-dev | libboost-filesystem1.35-dev,
libboost-signals-dev | libboost-signals1.35-dev,
libsenf (=${source:Version}) | libsenf-dbg (=${source:Version})
application layer. However, the framework includes many general
purpose utilities and will be expedient to use well beyond its primary
objective.
+
+Package: libsenf-tools
+Section: libdevel
+Architecture: any
+Depends: ${shlibs:Depends}
+Description: SENF Extensible Network Framework, utilities
+ The SENF Simple and Extensible Network Framework aims to be a
+ complete set of libraries to facilitate the development of network
+ applications focusing on network protocols on the layers below the
+ application layer. However, the framework includes many general
+ purpose utilities and will be expedient to use well beyond its primary
+ objective.
debian/tmp/usr/lib/libsenf_g.a
-debian/tmp/usr/lib/senf/debug/*_g.o usr/lib/senf
+debian/tmp/usr/lib/senf/senf_g.conf
+debian/tmp/usr/lib/senf/debug/* usr/lib/senf
README usr/share/doc/libsenf-dbg
debian/README.Debian usr/share/doc/libsenf-dbg
-debian/tmp/usr/include/senf usr/include
+debian/tmp/usr/include/senf
+debian/tmp/usr/lib/senf/site_scons
README usr/share/doc/libsenf-dev
debian/README.Debian usr/share/doc/libsenf-dev
debian/tmp/usr/share/doc/libsenf-doc
-debian/index.html usr/share/doc/libsenf-doc
README usr/share/doc/libsenf-doc
debian/README.Debian usr/share/doc/libsenf-doc
--- /dev/null
+debian/tmp/usr/bin
+README usr/share/doc/libsenf-dev
+debian/README.Debian usr/share/doc/libsenf-dev
debian/tmp/usr/lib/libsenf.a
-debian/tmp/usr/lib/senf/final/*.o usr/lib/senf
+debian/tmp/usr/lib/senf/senf.conf
+debian/tmp/usr/lib/senf/final/* usr/lib/senf
README usr/share/doc/libsenf
debian/README.Debian usr/share/doc/libsenf
dh_installdirs -i
# Add here commands to install the indep part of the package into
# debian/<package>-doc.
- dh_install -X.svn -i
+ dh_install -X.svn -X.git -i
install-arch: build-arch
dh_testdir
dh_installdirs -s
# Add here commands to install the arch part of the package into
# debian/tmp.
- dh_install -X.svn -s
+ dh_install -X.svn -X.git -s
# Must not depend on anything. This is to be called by
# binary-arch/binary-indep