[med-svn] [Git][med-team/libace-perl][master] 3 commits: d/p/cross.patch, d/rules, d/control: Make build cross buildable

Nilesh Patra (@nilesh) gitlab at salsa.debian.org
Tue Jun 1 22:01:06 BST 2021



Nilesh Patra pushed to branch master at Debian Med / libace-perl


Commits:
7afbb565 by Nilesh Patra at 2021-06-02T02:08:15+05:30
d/p/cross.patch,d/rules,d/control: Make build cross buildable

- - - - -
267b4d7c by Nilesh Patra at 2021-06-02T02:28:14+05:30
d/README.Debian: Fix file path

- - - - -
f3e71865 by Nilesh Patra at 2021-06-02T02:30:37+05:30
Interim changelog entry

- - - - -


6 changed files:

- debian/README.Debian
- debian/changelog
- debian/control
- + debian/patches/cross.patch
- debian/patches/series
- debian/rules


Changes:

=====================================
debian/README.Debian
=====================================
@@ -5,10 +5,10 @@ When rebuilding the package with latest packaging standards and
 comparing with previous content it was noticed that some settings
 definitely are not sanely chosen.  Since this was also not done
 before this fact is not changed but mentioned here to enable
-tracking down potential problems quickly.  Se questionable settings
+tracking down potential problems quickly. See questionable settings
 are in the file
 
-   /usr/lib/perl5/Ace/Browser/LocalSiteDefs.pm
+   /usr/lib/@DEB_HOST_MULTIARCH@/perl5/5.32/Ace/Browser/LocalSiteDefs.pm
 
 where the build directory remains hardcoded:
 


=====================================
debian/changelog
=====================================
@@ -1,3 +1,12 @@
+libace-perl (1.92-11) UNRELEASED; urgency=medium
+
+  * Team Upload.
+  * d/p/cross.patch,d/rules,d/control: Make build cross buildable
+    (Closes: #989367)
+  * d/README.Debian: Fix file path
+
+ -- Nilesh Patra <nilesh at debian.org>  Wed, 02 Jun 2021 02:30:02 +0530
+
 libace-perl (1.92-10) unstable; urgency=medium
 
   * Team upload.


=====================================
debian/control
=====================================
@@ -6,7 +6,8 @@ Section: perl
 Testsuite: autopkgtest-pkg-perl
 Priority: optional
 Build-Depends: debhelper-compat (= 13),
-               libtirpc-dev
+               libtirpc-dev,
+               perl-xs-dev
 Standards-Version: 4.5.1
 Vcs-Browser: https://salsa.debian.org/med-team/libace-perl
 Vcs-Git: https://salsa.debian.org/med-team/libace-perl.git


=====================================
debian/patches/cross.patch
=====================================
@@ -0,0 +1,78 @@
+Description: Use host compiler and linker instead of build compiler
+Author: Nilesh Patra <nilesh at debian.org>
+Last-Update: 2021-06-01
+--- a/acelib/Makefile
++++ b/acelib/Makefile
+@@ -2,6 +2,7 @@
+ false = 0
+ RANLIB_NEEDED = true	# default overridable in $(ACEDB_MACHINE)_DEF
+ AR_OPTIONS = rlu	# default overridable in $(ACEDB_MACHINE)_DEF
++AR = ar
+ 
+ RPCGEN_FLAGS = -I -K -1
+ # -I -K -1  good for alpha
+@@ -42,7 +43,7 @@
+ ## Different platforms use CC or COMPILE.c
+ #  (USEROPTS - see comments at top of file)
+ #
+-CC =        $(COMPILER) $(CFLAGS) $(CPPFLAGS) $(USEROPTS) $(IDIR) -D$(NAME) -c
++CC_compile =        $(COMPILER) $(CFLAGS) $(CPPFLAGS) $(USEROPTS) $(IDIR) -D$(NAME) -c
+ COMPILE.c = $(COMPILER) $(CFLAGS) $(CPPFLAGS) $(USEROPTS) $(IDIR) -D$(NAME) -c
+ 
+ ###########################################################
+@@ -63,11 +64,11 @@
+ ################## libraries #########################
+ 
+ libaceperl.a : $(FREE_OBJS) aceclientlib.o rpcace_clnt.o rpcace_xdr.o
+-	ar $(AR_OPTIONS) $@ $?
++	$(AR) $(AR_OPTIONS) $@ $?
+ 	if ( $(RANLIB_NEEDED) ) then ranlib $@; fi
+ 
+ libfree.a : $(FREE_OBJS)
+-	ar $(AR_OPTIONS) libfree.a $?
++	$(AR) $(AR_OPTIONS) libfree.a $?
+ 	if ( $(RANLIB_NEEDED) ) then ranlib libfree.a; fi
+ 
+ #########################################
+@@ -87,7 +88,7 @@
+ LIBACE_OBJS = $(GENERIC_ACE_OBJS) $(GENERIC_ACE_NONGRAPH_OBJS) aceversion.o
+ 
+ libace.a :  $(LIBACE_OBJS)
+-	ar $(AR_OPTIONS) libace.a $?
++	$(AR) $(AR_OPTIONS) libace.a $?
+ 	if ( $(RANLIB_NEEDED) ) then ranlib libace.a; fi
+ 
+ ######################################################
+@@ -106,7 +107,7 @@
+ rpcace_sp.o: rpcace_sp.c rpcace_svc.c
+ 
+ aceclientlib.o: aceclientlib.c rpcace.h
+-	$(CC) $(LDFLAGS) -c $<
++	$(CC_compile) $(LDFLAGS) -c $<
+ 
+ RPC_CLIENT_OBJS = aceclientlib.o rpcace_clnt.o rpcace_xdr.o
+ RPC_SERVER_OBJS = rpcace_sp.o  rpcace_xdr.o 
+@@ -114,7 +115,7 @@
+ RPC_X_CLIENT_OBJS = xclient.o aceclientlib.o rpcace_clnt.o rpcace_xdr.o
+ 
+ libacecl.a : aceclientlib.o rpcace_clnt.o rpcace_xdr.o
+-	ar $(AR_OPTIONS) libacecl.a $?
++	$(AR) $(AR_OPTIONS) libacecl.a $?
+ 	if ( $(RANLIB_NEEDED) ) then ranlib libacecl.a; fi
+ 
+ ###########################################################
+--- a/acelib/wmake/LINUX_DEF
++++ b/acelib/wmake/LINUX_DEF
+@@ -15,9 +15,10 @@
+ #####   following the explanations given in wmake/truemake  #####
+ #################################################################
+ 
++CC = gcc
+ NAME = LINUX
+-COMPILER = gcc -g -Wall -O2 -DACEDB4
+-LINKER = gcc -g
++COMPILER = $(CC) -g -Wall -O2 -DACEDB4
++LINKER = $(CC) -g
+ USEROPTS=-fPIC
+ 
+ LIBS = -lm


=====================================
debian/patches/series
=====================================
@@ -3,3 +3,4 @@ parallel-ftbfs.patch
 defined_hash_array.patch
 libtirpc.patch
 hardening.patch
+cross.patch


=====================================
debian/rules
=====================================
@@ -5,6 +5,10 @@ PACKAGE = $(shell dh_listpackages)
 TMP     = $(CURDIR)/debian/$(PACKAGE)
 
 export DEB_BUILD_MAINT_OPTIONS=hardening=+all
+include /usr/share/dpkg/buildtools.mk
+include /usr/share/dpkg/architecture.mk
+PERLVER := $(shell perl -MConfig -e 'print $$Config{version}')
+ARCHLIB := $(shell perl -I/usr/lib/$(DEB_HOST_MULTIARCH)/perl/cross-config-$(PERLVER) -MConfig -e 'print $$Config{vendorarch}')
 
 %:
 	dh  $@
@@ -27,8 +31,9 @@ override_dh_auto_build:
 	# Directory for the acebrowser CGI scripts (~username ok): [/usr/local/apache/cgi-bin/ace]
 	# Directory does not exist.  Shall I create it for you? [y]
 	# Directory for the acebrowser HTML files and images (~username ok): [/usr/local/apache/htdocs/ace]
-	perl -e "print qq(3\ny\n$(CURDIR)/debian/$(PACKAGE)/etc/libace-perl\ny\n$(CURDIR)/debian/$(PACKAGE)/usr/lib/cgi-bin\ny\n$(CURDIR)/debian/$(PACKAGE)/usr/share/$(PACKAGE))" | $(PERL) Makefile.PL INSTALLDIRS=vendor
-	dh_auto_build -- OPTIMIZE="$(CFLAGS)" LD_RUN_PATH="" OTHERLDFLAGS="$(LDFLAGS)"
+	perl -e "print qq(3\ny\n$(CURDIR)/debian/$(PACKAGE)/etc/libace-perl\ny\n$(CURDIR)/debian/$(PACKAGE)/usr/lib/cgi-bin\ny\n$(CURDIR)/debian/$(PACKAGE)/usr/share/$(PACKAGE))" | $(PERL) Makefile.PL \
+	INSTALLDIRS=vendor CC=$(CC) LD=$(CC) INSTALLVENDORARCH=$(ARCHLIB) INSTALLARCHLIB=$(ARCHLIB)
+	dh_auto_build --buildsystem=makefile -- OPTIMIZE="$(CFLAGS)" LD_RUN_PATH="" OTHERLDFLAGS="$(LDFLAGS)"
 
 override_dh_auto_test:
 ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
@@ -41,6 +46,7 @@ override_dh_clean:
 	dh_clean .docs Ace/Browser/LocalSiteDefs.pm docs/Ace.html pod2htmd.tmp pod2htmi.tmp util/ace.pl util/install.pl
 
 override_dh_auto_install:
+	sed -i 's/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/g' debian/README.Debian
 	# Add commands to install the package into $(TMP)
 	$(MAKE) install DESTDIR=$(TMP) PREFIX=/usr
 	mv $(TMP)/usr/bin/ace.pl $(TMP)/usr/bin/ace



View it on GitLab: https://salsa.debian.org/med-team/libace-perl/-/compare/106826902ca49dc418f2cc8d7c5fbf6f05603967...f3e7186529c4d2eec156cff0f42e30a56ddbbbb8

-- 
View it on GitLab: https://salsa.debian.org/med-team/libace-perl/-/compare/106826902ca49dc418f2cc8d7c5fbf6f05603967...f3e7186529c4d2eec156cff0f42e30a56ddbbbb8
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/20210601/583dae69/attachment-0001.htm>


More information about the debian-med-commit mailing list