1 |
commit: c0ca48ec9827893cd6ab278bd09bbc0865f61630 |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Mar 1 10:54:33 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Mar 1 10:56:45 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c0ca48ec |
7 |
|
8 |
games-strategy/0ad: fix AR/RANLIB usage |
9 |
|
10 |
Closes: https://bugs.gentoo.org/773511 |
11 |
Closes: https://bugs.gentoo.org/773502 |
12 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
13 |
|
14 |
games-strategy/0ad/0ad-0.0.24b_alpha.ebuild | 5 ++-- |
15 |
.../0ad/files/0ad-0.0.24b_alpha-respect-tc.patch | 32 ++++++++++++++++++++++ |
16 |
2 files changed, 34 insertions(+), 3 deletions(-) |
17 |
|
18 |
diff --git a/games-strategy/0ad/0ad-0.0.24b_alpha.ebuild b/games-strategy/0ad/0ad-0.0.24b_alpha.ebuild |
19 |
index 2e003b33f53..e7596872128 100644 |
20 |
--- a/games-strategy/0ad/0ad-0.0.24b_alpha.ebuild |
21 |
+++ b/games-strategy/0ad/0ad-0.0.24b_alpha.ebuild |
22 |
@@ -76,6 +76,7 @@ RDEPEND=" |
23 |
PATCHES=( |
24 |
"${FILESDIR}"/${PN}-0.0.24_alpha_pre20210116040036-build.patch |
25 |
"${FILESDIR}"/${PN}-0.0.24b_alpha-rust-1.50.patch |
26 |
+ "${FILESDIR}"/${PN}-0.0.24b_alpha-respect-tc.patch |
27 |
) |
28 |
|
29 |
pkg_setup() { |
30 |
@@ -106,7 +107,7 @@ src_configure() { |
31 |
--datadir="/usr/share/${PN}" |
32 |
) |
33 |
|
34 |
- tc-export CC CXX |
35 |
+ tc-export AR CC CXX RANLIB |
36 |
|
37 |
# Stock premake5 does not work, use the shipped one |
38 |
# TODO: revisit this, see above BDEPEND note re premake5 |
39 |
@@ -132,8 +133,6 @@ src_configure() { |
40 |
} |
41 |
|
42 |
src_compile() { |
43 |
- tc-export AR |
44 |
- |
45 |
# Build 3rd party fcollada |
46 |
einfo "Building bundled fcollada" |
47 |
emake -C libraries/source/fcollada/src |
48 |
|
49 |
diff --git a/games-strategy/0ad/files/0ad-0.0.24b_alpha-respect-tc.patch b/games-strategy/0ad/files/0ad-0.0.24b_alpha-respect-tc.patch |
50 |
new file mode 100644 |
51 |
index 00000000000..7503ffc001b |
52 |
--- /dev/null |
53 |
+++ b/games-strategy/0ad/files/0ad-0.0.24b_alpha-respect-tc.patch |
54 |
@@ -0,0 +1,32 @@ |
55 |
+--- a/libraries/source/fcollada/src/Makefile |
56 |
++++ b/libraries/source/fcollada/src/Makefile |
57 |
+@@ -7,6 +7,7 @@ |
58 |
+ PIC_FLAGS ?= -fpic |
59 |
+ endif |
60 |
+ |
61 |
++AR? ?= ar |
62 |
+ CXX ?= g++ |
63 |
+ CXXFLAGS += -fvisibility=hidden -W -Wall -Wno-unused-parameter -Wno-unused-function $(OS_DEFINE) $(PIC_FLAGS) $(CPPFLAGS) |
64 |
+ CXXFLAGS_DEBUG := -D_DEBUG -DRETAIL |
65 |
+@@ -16,6 +17,7 @@ |
66 |
+ LIBS += `pkg-config libxml-2.0 --libs` |
67 |
+ INCLUDES += -IFCollada `pkg-config libxml-2.0 --cflags` |
68 |
+ INCLUDES_TEST := -IFCollada/FColladaTest $(INCLUDES) |
69 |
++RANLIB ?= ranlib |
70 |
+ |
71 |
+ # FCollada is not aliasing-safe, so disallow dangerous optimisations |
72 |
+ # (TODO: It'd be nice to fix FCollada, but that looks hard) |
73 |
+@@ -246,11 +248,11 @@ |
74 |
+ |
75 |
+ output/libFColladaSD.a: $(OBJECTS_DEBUG) | output_dirs |
76 |
+ @echo "$@" |
77 |
+- @ar -cr $@ $(OBJECTS_DEBUG); ranlib $@ |
78 |
++ @$(AR) -cr $@ $(OBJECTS_DEBUG); $(RANLIB) $@ |
79 |
+ |
80 |
+ output/libFColladaSR.a: $(OBJECTS_RELEASE) | output_dirs |
81 |
+ @echo "$@" |
82 |
+- @ar -cr $@ $(OBJECTS_RELEASE); ranlib $@ |
83 |
++ @$(AR) -cr $@ $(OBJECTS_RELEASE); $(RANLIB) $@ |
84 |
+ |
85 |
+ output/FColladaTest: $(OBJECTS_TEST) | output_dirs |
86 |
+ $(CXX) -o $@ $(OBJECTS_TEST) $(LIBS) $(LDFLAGS_TEST) |