Rework configure invocation:
authorAaron M. Ucko <ucko@debian.org>
Sun, 29 May 2011 14:53:03 +0000 (14:53 +0000)
committerAaron M. Ucko <ucko@debian.org>
Sun, 29 May 2011 14:53:03 +0000 (14:53 +0000)
+ --with-runpath=/usr/lib/ncbi-blast+ (where the libraries will end up)
+ --with-flat-makefile (making it easier to skip irrelevant projects)
+ --without-lzo (to avoid picking up an extra dependency in some environments)
+ --without-autodep and --without-makefile-auto-update for streamlining.
+ --with-build-root=BUILD for predictable paths
* --without-debug -> --with-optimization when DEB_BUILD_OPTIONS contains
  nostrip.  Doing so unconditionally would be cleaner, as that change also
  switches from -DNDEBUG to -D_DEBUG, but that detail isn't worth demanding
  extra build-time resources by default.
- --without-gbench, --without-internal, and --with-3psw=std:netopt (superfluous)
- --bindir=*, --libdir=*, --prefix=* (files now installed directly)
Supply LD_LIBRARY_PATH so that project_tree_builder can find the libraries it
needs and --with-flat-makefile is effective.

debian/rules

index e5289d5f8192348e610ac01245d404917de0062d..0db1c1cf44bdd178e95d9a48a918eb8dd6514364 100755 (executable)
 #export DH_VERBOSE=1
 
 SOURCEDIR=${CURDIR}/c++
-export DEB_CONFIGURE_EXTRA_FLAGS= --with-dll --without-debug --with-mt  --without-gbench --without-internal  \
-    --libdir=${CURDIR}/debian/ncbi-blast+/usr/lib/ncbi-blast+  --bindir=${CURDIR}/debian/ncbi-blast+/usr/bin \
-    --includedir=$(SOURCEDIR)/include  --with-3psw=std:netopt  --without-dbapi
+DEB_CONFIGURE_EXTRA_FLAGS=--with-dll --with-mt --without-autodep \
+    --without-makefile-auto-update --with-flat-makefile --without-dbapi \
+    --without-lzo --with-runpath=/usr/lib/ncbi-blast+ --with-build-root=BUILD
+
+# XXX - not quite right, as we get -DNDEBUG vs. -D_DEBUG
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+DEB_CONFIGURE_EXTRA_FLAGS += --without-debug
+else
+DEB_CONFIGURE_EXTRA_FLAGS += --with-optimization
+endif
+
 
 override_dh_auto_configure:
-       ( cd $(SOURCEDIR) ; ./configure ${DEB_CONFIGURE_EXTRA_FLAGS} --prefix=${SOURCEDIR}/debian/ncbi-blast+ )
+       cd c++  &&  LD_LIBRARY_PATH=$(CURDIR)/c++/BUILD/lib \
+           ./configure $(DEB_CONFIGURE_EXTRA_FLAGS)
 
 
 instroot = debian/ncbi-blast+/usr