[med-svn] [Git][med-team/hmmer2][master] 4 commits: Update PKG_CONFIG macro in configure.ac and avoid hard-coding the same to get...

Nilesh Patra (@nilesh) gitlab at salsa.debian.org
Mon Mar 25 12:12:34 GMT 2024



Nilesh Patra pushed to branch master at Debian Med / hmmer2


Commits:
ea080a4f by Nilesh Patra at 2024-03-25T17:06:22+05:30
Update PKG_CONFIG macro in configure.ac and avoid hard-coding the same to get package cross-building

- - - - -
7d207224 by Nilesh Patra at 2024-03-25T17:08:11+05:30
Since tests are compiled during build time, cleanup before running dh_installexamples

- - - - -
e02dcb39 by Nilesh Patra at 2024-03-25T17:27:19+05:30
Fixup wrong paths in .pc file

- - - - -
87fe57c5 by Nilesh Patra at 2024-03-25T17:34:53+05:30
Upload to unstable

- - - - -


6 changed files:

- debian/changelog
- debian/libhmmer2-dev.install
- debian/missing-sources/configure.ac
- debian/patches/use_debian_packaged_biosquid.patch
- debian/pkgconfig/libhmmer2.pc → debian/pkgconfig/libhmmer2.pc.in
- debian/rules


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,14 @@
+hmmer2 (2.3.2+dfsg-10) unstable; urgency=medium
+
+  * Team Upload.
+  * Update PKG_CONFIG macro in configure.ac and avoid
+    hard-coding the same to get package cross-building
+  * Since tests are compiled during build time, cleanup
+    before running dh_installexamples
+  * Fixup wrong paths in .pc file
+
+ -- Nilesh Patra <nilesh at iki.fi>  Mon, 25 Mar 2024 17:34:19 +0530
+
 hmmer2 (2.3.2+dfsg-9) unstable; urgency=medium
 
    * Team Upload.


=====================================
debian/libhmmer2-dev.install
=====================================
@@ -5,4 +5,4 @@ src/globals.h		usr/include/hmmer2
 src/postprob.h		usr/include/hmmer2
 src/structs.h		usr/include/hmmer2
 src/libhmmer.a		usr/lib/${DEB_HOST_MULTIARCH}
-debian/pkgconfig	usr/lib/${DEB_HOST_MULTIARCH}
+debian/pkgconfig/libhmmer2.pc	usr/lib/${DEB_HOST_MULTIARCH}/pkgconfig/


=====================================
debian/missing-sources/configure.ac
=====================================
@@ -73,6 +73,14 @@ AC_PROG_CC
 AC_PROG_RANLIB
 AC_PATH_PROG([AR], [ar], [:], [$PATH:/usr/ccs/bin:/usr/xpg4/bin])
 
+dnl directive for enabling PKG_CONFIG
+PKG_PROG_PKG_CONFIG
+AS_IF([test "x$PKG_CONFIG" = "x"],[
+   AC_MSG_ERROR([
+      *** The pkg-config script could not be found. Make sure it is
+      *** in your path, or set the PKG_CONFIG environment variable
+      *** to the full path to pkg-config.])
+   ])
 
 # Figure out what host we're compiling on.
 # Three GNU scripts must be included in the distro: 


=====================================
debian/patches/use_debian_packaged_biosquid.patch
=====================================
@@ -5,36 +5,45 @@ Description: Link against Debian packaged libsquid and remove
 
 --- a/src/Makefile.in
 +++ b/src/Makefile.in
-@@ -42,9 +42,9 @@ PVMLIBS   = @PVMLIBS@
+@@ -18,6 +18,7 @@
+ CPPFLAGS = @CPPFLAGS@
+ LDFLAGS  = @LDFLAGS@
+ DEFS     = @DEFS@
++PKG_CONFIG = @PKG_CONFIG@
+ LIBS     = @LIBS@ -lm
+ 
+ ## archiving command, and ranlib command if you need one.
+@@ -42,9 +43,9 @@
  PVMPROGS  = @PVMPROGS@
  
  SHELL    = /bin/sh
 -MYLIBS   = -lsquid
 -MYLIBDIR = -L../squid
 -MYINCDIR = -I../squid
-+MYLIBS   = `pkg-config --libs libsquid`
++MYLIBS   = `$(PKG_CONFIG) --libs libsquid`
 +MYLIBDIR = 
-+MYINCDIR = `pkg-config --cflags libsquid`
++MYINCDIR = `$(PKG_CONFIG) --cflags libsquid`
  
  PROGS = hmmalign\
  	hmmbuild\
 --- a/testsuite/Makefile.in
 +++ b/testsuite/Makefile.in
-@@ -17,7 +17,7 @@ CPPFLAGS  = @CPPFLAGS@
+@@ -17,7 +17,8 @@
  LDFLAGS   = @LDFLAGS@
  DEFS      = @DEFS@
  LIBS      = @LIBS@ -lm
 -MYLIBS    = -lhmmer -lsquid
-+MYLIBS    = -lhmmer `pkg-config --libs libsquid`
++PKG_CONFIG = @PKG_CONFIG@
++MYLIBS    = -lhmmer `$(PKG_CONFIG) --libs libsquid`
  
  # Configuration for optional pthreads multiprocessor support
  #
-@@ -40,12 +40,12 @@ SHIVA = alignalign_test\
+@@ -40,12 +41,12 @@
  #######
  
  .c.o:
 -	$(CC) $(CFLAGS) $(PTHREAD_CFLAGS) ${CPPFLAGS} $(DEFS) -I../squid -I../src -c $<		
-+	$(CC) $(CFLAGS) $(PTHREAD_CFLAGS) ${CPPFLAGS} $(DEFS) `pkg-config --cflags libsquid` -I../src -c $<		
++	$(CC) $(CFLAGS) $(PTHREAD_CFLAGS) ${CPPFLAGS} $(DEFS) `$(PKG_CONFIG) --cflags libsquid` -I../src -c $<		
  
  all: 	$(SHIVA)
  
@@ -46,7 +55,7 @@ Description: Link against Debian packaged libsquid and remove
  ## `make check` actually runs the tests.
 --- a/src/funcs.h
 +++ b/src/funcs.h
-@@ -181,7 +181,6 @@ extern void  LogNorm(float *vec, int n);
+@@ -181,7 +181,6 @@
  extern float Logp_cvec(float *cvec, int n, float *alpha);
  extern void  SampleDirichlet(float *alpha, int n, float *p);
  extern float SampleGamma(float alpha);
@@ -56,7 +65,7 @@ Description: Link against Debian packaged libsquid and remove
  /* from misc.c
 --- a/src/mathsupport.c
 +++ b/src/mathsupport.c
-@@ -320,23 +320,6 @@ SampleGamma(float alpha)
+@@ -320,23 +320,6 @@
    return 0.0;
  }
  
@@ -82,7 +91,7 @@ Description: Link against Debian packaged libsquid and remove
   * 
 --- a/configure
 +++ b/configure
-@@ -2597,11 +2597,11 @@ if test "${enable_lfs+set}" = set; then
+@@ -2597,11 +2597,11 @@
     yes) { echo "$as_me:$LINENO: configured for optional LFS, large file support" >&5
  echo "$as_me: configured for optional LFS, large file support" >&6;}
  	cat >>confdefs.h <<\_ACEOF
@@ -109,7 +118,7 @@ Description: Link against Debian packaged libsquid and remove
  /* --enable-pvm          Parallel Virtual Machine (PVM)
 --- a/Makefile.in
 +++ b/Makefile.in
-@@ -87,7 +87,6 @@ all:
+@@ -87,7 +87,6 @@
  	  echo "If you really want to rebuild from source, move or delete the" ;\
  	  echo "binaries/ subdirectory."; \
  	else\
@@ -117,7 +126,7 @@ Description: Link against Debian packaged libsquid and remove
  	  (cd src;       ${MAKE}; ${MAKE} module);\
  	  (cd testsuite; ${MAKE});\
  	fi
-@@ -98,9 +97,6 @@ all:
+@@ -98,9 +97,6 @@
  check:	
  	(cd testsuite; make check)
  
@@ -127,7 +136,7 @@ Description: Link against Debian packaged libsquid and remove
  src/libhmmer.a: 
  	(cd src;   make; make module)
  
-@@ -143,7 +139,6 @@ bindist:
+@@ -143,7 +139,6 @@
  #
  clean:
  	(cd src;       make clean)
@@ -135,7 +144,7 @@ Description: Link against Debian packaged libsquid and remove
  	(cd testsuite; make clean)
  	-rm -f *.o *~ Makefile.bak core TAGS gmon.out
  
-@@ -156,7 +151,6 @@ distclean:
+@@ -156,7 +151,6 @@
  	-rm -f *.o *~ Makefile.bak core TAGS gmon.out
  	-rm Makefile
  	(cd src;       make distclean)
@@ -143,7 +152,7 @@ Description: Link against Debian packaged libsquid and remove
  	(cd testsuite; make distclean)
  
  
-@@ -165,7 +159,6 @@ distclean:
+@@ -165,7 +159,6 @@
  #
  binclean:
  	(cd src;       make binclean)


=====================================
debian/pkgconfig/libhmmer2.pc → debian/pkgconfig/libhmmer2.pc.in
=====================================
@@ -1,10 +1,10 @@
 prefix=/usr
 exec_prefix=${prefix}
-libdir=${prefix}/lib/x86_64-linux-gnu
+libdir=${prefix}/lib/@DEB_HOST_MULTIARCH@
 includedir=${prefix}/include/hmmer2
 
 Name: libhmmer2
-Version: 2.3.2
+Version: @VERSION@
 Description: profile hidden Markov models for protein sequence analysis
 Libs: -L${libdir} -lhmmer
 Cflags: -I${includedir}


=====================================
debian/rules
=====================================
@@ -8,6 +8,8 @@ endif
 
 pkgdata:=hmmer2
 sampledir:=$(CURDIR)/debian/$(pkgdata)/usr/share/doc/$(pkgdata)/examples
+include /usr/share/dpkg/pkg-info.mk
+UPSTREAM_VERSION := $(shell echo $(DEB_VERSION_UPSTREAM) | sed -e 's,+dfsg,,g')
 
 export AUTOHEADER = 'true'
 
@@ -66,7 +68,14 @@ ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
 	cd testsuite && make clean
 endif
 
+override_dh_install:
+	sed -e "s/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/" \
+		-e "s/@VERSION@/$(UPSTREAM_VERSION)/" debian/pkgconfig/libhmmer2.pc.in > debian/pkgconfig/libhmmer2.pc
+	dh_install
+	rm -f debian/pkgconfig/libhmmer2.pc
+
 override_dh_installexamples:
+	cd testsuite && make clean && cd ..
 	dh_installexamples
 	mkdir -p $(sampledir);
 	cp -a testsuite/* $(sampledir)/;



View it on GitLab: https://salsa.debian.org/med-team/hmmer2/-/compare/04766961c8a832c97312b22a09f0dd61bc098504...87fe57c5b4ae62513d77aba56d942914ca93c48d

-- 
View it on GitLab: https://salsa.debian.org/med-team/hmmer2/-/compare/04766961c8a832c97312b22a09f0dd61bc098504...87fe57c5b4ae62513d77aba56d942914ca93c48d
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/20240325/36022a3e/attachment-0001.htm>


More information about the debian-med-commit mailing list