[med-svn] [Git][med-team/ncbi-blastplus][master] 7 commits: Start work on ncbi-blast+ 2.9.0-2, primarily for #930240.

Aaron M. Ucko gitlab at salsa.debian.org
Mon Sep 30 04:50:06 BST 2019



Aaron M. Ucko pushed to branch master at Debian Med / ncbi-blastplus


Commits:
9682d07d by Aaron M. Ucko at 2019-09-29T19:37:27Z
Start work on ncbi-blast+ 2.9.0-2, primarily for #930240.

- - - - -
de8ac77e by Aaron M. Ucko at 2019-09-29T19:40:26Z
debian/rules: Use /usr/share/dpkg/{architecture,buildflags}.mk.

Delegate dpkg-{architecture,buildflags} calls to
/usr/share/dpkg/{architecture,buildflags}.mk respectively.

- - - - -
fdbb78f4 by Aaron M. Ucko at 2019-09-30T01:50:15Z
debian/rules: Allow for cross-building (Closes: #930240).

- Factor a DEB_CONFIGURE_COMMON_FLAGS macro out of
  DEB_CONFIGURE_EXTRA_FLAGS for flags that also make sense for native
  builds of internal helpers.
- Conditionally supply --build=... and --host= to the main
  (historically, only) configure run per Helmut Grohne's suggestion.
  (dh_auto_configure would take care of this, but insists on passing
  a --runstatedir=... flag this configure script doesn't accept.)
- Conditionally add a rule for building native datatool and
  project_tree_builder binaries (in a parallel build tree established
  via another configure invocation), make it a dependency of
  override_dh_auto_configure-arch, and arrange for everything else to
  use these binaries as needed.
- Honor DEB_BUILD_OPTIONS="... nocheck ...", also per Helmut.
- Rework logic to install (possibly indirect) local library
  dependencies to use readelf rather than ldd, making as many passes
  as necessary (four at present, but no hardcoded count).

- - - - -
3f95d82b by Aaron M. Ucko at 2019-09-30T01:54:40Z
debian/rules: Install get_species_taxids without the .sh suffix.

- - - - -
5ab1958e by Aaron M. Ucko at 2019-09-30T01:55:46Z
debian/copyright: Remove redundant ncbi_menu_*.js stanza.

- - - - -
67053dfe by Aaron M. Ucko at 2019-09-30T01:56:58Z
debian/control: Standards-Version: 4.4.1 (already compliant).

- - - - -
bd00a267 by Aaron M. Ucko at 2019-09-30T01:57:32Z
Finalize ncbi-blast+ 2.9.0-2 for upload to unstable.

- - - - -


4 changed files:

- debian/changelog
- debian/control
- debian/copyright
- debian/rules


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,31 @@
+ncbi-blast+ (2.9.0-2) unstable; urgency=medium
+
+  * debian/control: Standards-Version: 4.4.1 (already compliant).
+  * debian/copyright: Remove redundant ncbi_menu_*.js stanza.
+  * debian/rules:
+    - Delegate dpkg-{architecture,buildflags} calls to
+      /usr/share/dpkg/{architecture,buildflags}.mk respectively.
+    - Allow for cross-building (Closes: #930240):
+    -- Factor a DEB_CONFIGURE_COMMON_FLAGS macro out of
+       DEB_CONFIGURE_EXTRA_FLAGS for flags that also make sense for native
+       builds of internal helpers.
+    -- Conditionally supply --build=... and --host= to the main
+       (historically, only) configure run per Helmut Grohne's suggestion.
+       (dh_auto_configure would take care of this, but insists on passing
+       a --runstatedir=... flag this configure script doesn't accept.)
+    -- Conditionally add a rule for building native datatool and
+       project_tree_builder binaries (in a parallel build tree established
+       via another configure invocation), make it a dependency of
+       override_dh_auto_configure-arch, and arrange for everything else to
+       use these binaries as needed.
+    -- Honor DEB_BUILD_OPTIONS="... nocheck ...", also per Helmut.
+    -- Rework logic to install (possibly indirect) local library
+       dependencies to use readelf rather than ldd, making as many passes
+       as necessary (four at present, but no hardcoded count).
+    - Install get_species_taxids without the .sh suffix.
+
+ -- Aaron M. Ucko <ucko at debian.org>  Sun, 29 Sep 2019 21:57:31 -0400
+
 ncbi-blast+ (2.9.0-1) unstable; urgency=medium
 
   * New upstream release 


=====================================
debian/control
=====================================
@@ -16,7 +16,7 @@ Build-Depends-Arch: 2to3,
                libpcre3-dev,
                time,
                zlib1g-dev
-Standards-Version: 4.3.0
+Standards-Version: 4.4.1
 Vcs-Browser: https://salsa.debian.org/med-team/ncbi-blastplus
 Vcs-Git: https://salsa.debian.org/med-team/ncbi-blastplus.git
 Homepage: http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/


=====================================
debian/copyright
=====================================
@@ -165,14 +165,6 @@ License: GPL-2
  Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
 
 
-Files: c++/src/html/ncbi_menu_*.js
-Copyright: 1997-1999 Netscape Communications Corp.
-License: Netscape
- Netscape grants you a royalty free license to use or modify this
- software provided that this copyright notice appears on all copies.
- This software is provided "AS IS," without a warranty of any kind.
-
-
 Files: c++/include/util/bitset/*
 Copyright: 2002-2003 Anatoliy Kuznetsov
 License: MIT


=====================================
debian/rules
=====================================
@@ -9,12 +9,12 @@ ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
     NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
 endif
 
+DEB_CONFIGURE_COMMON_FLAGS=--without-autodep --without-makefile-auto-update \
+    --with-flat-makefile --without-caution --without-dbapi --without-lzo \
+    --without-debug --without-downloaded-vdb
+DEB_CONFIGURE_EXTRA_FLAGS=$(DEB_CONFIGURE_COMMON_FLAGS) --with-dll --with-mt \
+    --with-runpath=/usr/lib/ncbi-blast+ --with-build-root=BUILD --with-mbedtls
 
-DEB_CONFIGURE_EXTRA_FLAGS=--with-dll --with-mt --without-autodep \
-    --without-makefile-auto-update --with-flat-makefile --without-caution \
-    --without-dbapi --without-lzo --with-runpath=/usr/lib/ncbi-blast+ \
-    --with-build-root=BUILD --without-debug --without-downloaded-vdb \
-    --with-mbedtls
 proj=algo/blast/ app/ objmgr/ objtools/align_format/ objtools/blast/
 
 #ifneq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
@@ -26,12 +26,10 @@ export DEB_BUILD_MAINT_OPTIONS=hardening=+all,-pie
 export DEB_CFLAGS_MAINT_APPEND=-Wall -pedantic
 export DEB_LDFLAGS_MAINT_APPEND=-Wl,--as-needed
 
-DEB_HOST_ARCH := $(shell dpkg-architecture -qDEB_HOST_ARCH)
+include /usr/share/dpkg/architecture.mk
+include /usr/share/dpkg/buildflags.mk
 
-CFLAGS   := $(shell dpkg-buildflags --get CFLAGS)
-CPPFLAGS := $(shell dpkg-buildflags --get CPPFLAGS)
-CXXFLAGS := $(shell dpkg-buildflags --get CXXFLAGS)
-LDFLAGS  := $(shell dpkg-buildflags --get LDFLAGS) -Wl,--as-needed
+LDFLAGS += -Wl,--as-needed
 
 ifneq (,$(findstring mips,$(DEB_HOST_ARCH)))
 CXXFLAGS := $(CXXFLAGS:-O%=-O)
@@ -41,16 +39,33 @@ endif
 export CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MAKE
 
 # used for run_with_lock
-DEB_CONFIGURE_EXTRA_FLAGS +=  CFLAGS_FOR_BUILD="$(CFLAGS) -fPIE"
-DEB_CONFIGURE_EXTRA_FLAGS += LDFLAGS_FOR_BUILD="$(LDFLAGS)"
+DEB_CONFIGURE_COMMON_FLAGS +=  CFLAGS_FOR_BUILD="$(CFLAGS) -fPIE"
+DEB_CONFIGURE_COMMON_FLAGS += LDFLAGS_FOR_BUILD="$(LDFLAGS)"
 
 BLAST2_VERSION=1:$(shell dpkg-parsechangelog | awk '/^Version:/ { print $$2 }')
 
-llp=LD_LIBRARY_PATH
+ifneq ($(DEB_BUILD_ARCH),$(DEB_HOST_ARCH))
+NATIVE=.native
+DEB_CONFIGURE_EXTRA_FLAGS += --build=$(DEB_BUILD_GNU_TYPE) \
+    --host=$(DEB_HOST_GNU_TYPE)
+NATIVE_BINDIR=$(CURDIR)/c++/BUILD$(NATIVE)/bin
+PREBUILT_DATATOOL_EXE=$(NATIVE_BINDIR)/datatool
+PREBUILT_PTB_EXE=$(NATIVE_BINDIR)/project_tree_builder
+export PREBUILT_DATATOOL_EXE PREBUILT_PTB_EXE
+
+$(PREBUILT_DATATOOL_EXE):
+	cd c++  &&  PREBUILT_PTB_EXE=bootstrap \
+            ./configure $(DEB_CONFIGURE_COMMON_FLAGS) --without-objects \
+            --without-algo --without-app --with-build-root=BUILD.native  ||  \
+            (tail -v -n +0 config.log BUILD.native/status/config.log; exit 1)
+	make -j$(NUMJOBS) -C c++/BUILD$(NATIVE)/build -f Makefile.flat \
+	    datatool.exe
+endif
+
 override_dh_auto_configure-indep:;
-override_dh_auto_configure-arch:
-	cd c++  &&  $(llp)=$(CURDIR)/c++/BUILD/lib$${$(llp)+:$$$(llp)} \
-	    CONFIG_SHELL=/bin/bash ./configure $(DEB_CONFIGURE_EXTRA_FLAGS) \
+override_dh_auto_configure-arch: $(PREBUILT_DATATOOL_EXE)
+	cd c++  &&  CONFIG_SHELL=/bin/bash \
+            ./configure $(DEB_CONFIGURE_EXTRA_FLAGS) \
 	    ||  (tail -v -n +0 config.log BUILD/status/config.log; exit 1)
 
 override_dh_auto_build-arch:
@@ -62,9 +77,11 @@ override_dh_auto_build-indep:
 	echo "Save time and do nothing for architecture independent builds"
 
 override_dh_auto_test:
+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
 	-dh_auto_test
 	-c++/BUILD/build/check.sh concat_err
 	-cat c++/BUILD/build/check.sh.out_err
+endif
 
 instroot = debian/ncbi-blast+/usr
 leg_bin = debian/ncbi-blast+-legacy/usr/bin
@@ -79,6 +96,8 @@ override_dh_install-arch:
 	# dh_install
 	mv $(instroot)/bin/rpsblast $(instroot)/bin/rpsblast+
 	mv $(instroot)/bin/seedtop $(instroot)/bin/seedtop+
+	mv $(instroot)/bin/get_species_taxids.sh \
+	    $(instroot)/bin/get_species_taxids
 	mv $(instroot)/bin/legacy_blast.pl   $(instroot)/bin/legacy_blast
 	mv $(instroot)/bin/update_blastdb.pl $(instroot)/bin/update_blastdb
 	sed -e '1s/$$/3/' $(instroot)/bin/windowmasker_2.2.22_adapter.py \
@@ -90,10 +109,22 @@ override_dh_install-arch:
 	rm -f $(instroot)/bin/*test* $(instroot)/bin/seqdb_demo \
 	    $(instroot)/bin/datatool $(instroot)/bin/run_with_lock \
 	    $(instroot)/bin/project_tree_builder
-	for x in $(instroot)/bin/*; do \
-	    LD_LIBRARY_PATH=c++/BUILD/lib ldd $$x; \
-	done 2>/dev/null | awk '/BUILD/ { print $$3 }' | sort -u | \
-	xargs cp -v -t $(instroot)/lib/ncbi-blast+
+	mkdir c++/BUILD/lib.observed
+	d=$(instroot)/bin; \
+	while :; do \
+	    (for x in $$d/*; do \
+	        readelf -d $$x 2>/dev/null \
+	        | sed -ne 's/.*NEEDED.* \[\(.*\)]$$/\1/p'; \
+            done; rm -f c++/BUILD/lib.observed/*) | sort -u | while read l; do \
+	        [ -f $(instroot)/lib/ncbi-blast+/$$l \
+	          -o \! -f c++/BUILD/lib/$$l ]  || \
+	            cp -av c++/BUILD/lib/$$l c++/BUILD/lib.observed/; \
+	    done; \
+	    [ -n "$$(ls c++/BUILD/lib.observed)" ] || break; \
+	    echo ------------------------------------------------------------; \
+	    cp -a c++/BUILD/lib.observed/* $(instroot)/lib/ncbi-blast+; \
+	    d=c++/BUILD/lib.observed; \
+	done
 
 override_dh_install-indep:
 	#if test -d $(leg_bin); then cp debian/legacy/legacy.sh $(leg_bin)/; fi
@@ -118,14 +149,15 @@ override_dh_clean:
 		mods="`echo *.module`" ; \
 		[ "$${mods#*\*}" = "$$mods" ] || mods="`basename $$x`" ; \
 		for mod in $$mods ; do \
-       		    ../../../BUILD/build/new_module.sh $$mod purge_sources ; \
+	            ../../../BUILD$(NATIVE)/build/new_module.sh $$mod \
+	                purge_sources ; \
 		done ) ; \
 	    ) ; \
 	done
 	rm -rf c++/compilers/dll c++/config.log c++/Makefile
 	rm -f c++/configure.lineno c++/src/objects/blastxml/blastxml.module
 	find -name check_exec.pid -delete
-	rm -rf c++/BUILD
+	rm -rf c++/BUILD c++/BUILD.native
 	mv configure.orig.save c++/configure.orig
 	mv c++/src/util/lmdb/Makefile.orig.save c++/src/util/lmdb/Makefile.orig
 	mv c++/src/util/lmdbxx/Makefile.orig.save c++/src/util/lmdbxx/Makefile.orig



View it on GitLab: https://salsa.debian.org/med-team/ncbi-blastplus/compare/657af60fdd491321109fc2f5e68961ea7706b07e...bd00a2671eb95cdfdd16edfe5f0f048e931a6e02

-- 
View it on GitLab: https://salsa.debian.org/med-team/ncbi-blastplus/compare/657af60fdd491321109fc2f5e68961ea7706b07e...bd00a2671eb95cdfdd16edfe5f0f048e931a6e02
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20190930/8ed3e97f/attachment-0001.html>


More information about the debian-med-commit mailing list