Package: p7zip / 16.02+dfsg-3+deb9u1

03-include-linux-makefile.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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
From: Robert Luberda <robert@debian.org>
Date: Fri, 22 Jan 2016 11:16:14 +0100
Subject: Include linux makefile

Include appropriate makefile from makefile.machine
 - makefile.linux_x86_asm_gcc_4.X on i386;
 - makefile.linux_amd64_asm on amd64;
 - makefile.linux_any_cpu_gcc_4.X otherwise.

Update makefile.linux_amd64_asm to have the same visibility
flags as the *gcc_4.X makefiles.

Update makefile.linux_x86_asm_gcc_4.X to use yasm instead
of nasm.
---
 makefile.linux_amd64_asm       |  3 +++
 makefile.linux_x86_asm_gcc_4.X |  2 +-
 makefile.machine               | 20 ++++++++++++++++++++
 3 files changed, 24 insertions(+), 1 deletion(-)

diff --git a/makefile.linux_amd64_asm b/makefile.linux_amd64_asm
index 075c6a8..223559d 100644
--- a/makefile.linux_amd64_asm
+++ b/makefile.linux_amd64_asm
@@ -11,6 +11,9 @@ ALLFLAGS=-m64 ${OPTFLAGS} -pipe \
 	-D_7ZIP_ASM \
 	$(LOCAL_FLAGS)
 
+ALLFLAGS_CPP=-DENV_HAVE_GCCVISIBILITYPATCH -fvisibility=hidden -fvisibility-inlines-hidden
+
+
 CXX=g++
 CC=gcc
 CC_SHARED=-fPIC
diff --git a/makefile.linux_x86_asm_gcc_4.X b/makefile.linux_x86_asm_gcc_4.X
index 1ac339b..3b86ccc 100644
--- a/makefile.linux_x86_asm_gcc_4.X
+++ b/makefile.linux_x86_asm_gcc_4.X
@@ -18,7 +18,7 @@ CXX=g++
 CC=gcc
 CC_SHARED=-fPIC
 LINK_SHARED=-fPIC -shared
-ASM=nasm -f elf
+ASM=yasm -f elf
 
 PRE_COMPILED_HEADER=StdAfx.h.gch
 
diff --git a/makefile.machine b/makefile.machine
index 9e34c34..715e900 100644
--- a/makefile.machine
+++ b/makefile.machine
@@ -1,6 +1,25 @@
 #
 # makefile for Linux (x86, PPC, alpha ...)
 #
+ifeq (1,1) # In debian always include the approrpiate makefile
+
+  ifndef DEBIAN_P7ZIP_MAKEFILE
+
+    ifeq (i386,$(DEB_HOST_ARCH))
+        export DEBIAN_P7ZIP_MAKEFILE := makefile.linux_x86_asm_gcc_4.X
+    else
+      ifeq (amd64.64,$(DEB_HOST_ARCH).$(DEB_HOST_ARCH_BITS))
+        export DEBIAN_P7ZIP_MAKEFILE := makefile.linux_amd64_asm
+      else
+        export DEBIAN_P7ZIP_MAKEFILE := makefile.linux_any_cpu_gcc_4.X # default
+      endif
+    endif
+
+  endif
+
+  include $(dir $(lastword $(MAKEFILE_LIST)))/$(DEBIAN_P7ZIP_MAKEFILE)
+
+else
 
 OPTFLAGS=-O -s
 
@@ -21,3 +40,4 @@ LOCAL_LIBS_DLL=$(LOCAL_LIBS) -ldl
 OBJ_CRC32=$(OBJ_CRC32_C)
 OBJ_AES=
 
+endif