Package: exactimage / 1.0.2-1

Install-module-to-perl-vendor-path.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
From: Sven Eckelmann <sven@narfation.org>
Date: Sun, 22 Jun 2014 22:09:56 +0200
Subject: Install module to perl vendor path

Bug-Debian: https://bugs.debian.org/752344
Forwarded: not-needed
---
 api/perl/Makefile | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/api/perl/Makefile b/api/perl/Makefile
index 5408416..aa764a6 100644
--- a/api/perl/Makefile
+++ b/api/perl/Makefile
@@ -3,6 +3,7 @@ include build/top.make
 BINARY = ExactImage
 BINARY_EXT = $(X_DYNEXT)
 DEPS = $(image_BINARY) $(bardecode_BINARY) $(codecs_BINARY) $(api_BINARY) $($(X_MODULE)_OUTPUT)/api-perl-wrap.cc
+PERL_ARCHLIB := $(shell perl -MConfig -e 'print $$Config{vendorarch}')
 
 objdir/api/perl/CXXFLAGS := -I api $(PERLINCS)
 
@@ -20,5 +21,5 @@ X_BUILD_IMPLICIT := $(_X_BUILD_IMPLICIT)
 all:: $($(X_MODULE)_BINARY)
 install:: $($(X_MODULE)_BINARY)
 	$(Q)echo "INSTALL PERL module $^"
-	$(Q)mkdir -p $(DESTDIR)$(libdir)/perl5/site_perl/
-	$(Q)install $^ $(dir $^)/ExactImage.pm $(DESTDIR)$(libdir)/perl5/site_perl/
+	$(Q)mkdir -p $(DESTDIR)$(PERL_ARCHLIB)
+	$(Q)install $^ $(dir $^)/ExactImage.pm $(DESTDIR)$(PERL_ARCHLIB)