1 |
commit: cae0c8e14f6c43f8dcd94982cc3d977ae08da713 |
2 |
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Jan 29 22:50:47 2016 +0000 |
4 |
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jan 29 22:53:32 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cae0c8e1 |
7 |
|
8 |
sci-visualization/gnuplot: fix cross-compile builds |
9 |
|
10 |
The upstream build tries to set up CC_FOR_BUILD for building helper tools, |
11 |
but still mixes target compiler flags in which easily leads to failure. |
12 |
|
13 |
sci-visualization/gnuplot/gnuplot-4.6.5.ebuild | 9 +++++++++ |
14 |
sci-visualization/gnuplot/gnuplot-5.0.1-r1.ebuild | 10 ++++++++++ |
15 |
2 files changed, 19 insertions(+) |
16 |
|
17 |
diff --git a/sci-visualization/gnuplot/gnuplot-4.6.5.ebuild b/sci-visualization/gnuplot/gnuplot-4.6.5.ebuild |
18 |
index b5f2965..3dd44b2 100644 |
19 |
--- a/sci-visualization/gnuplot/gnuplot-4.6.5.ebuild |
20 |
+++ b/sci-visualization/gnuplot/gnuplot-4.6.5.ebuild |
21 |
@@ -104,6 +104,13 @@ src_prepare() { |
22 |
distributed separately; the gnuplot ebuild no longer installs it. |
23 |
Emerge app-emacs/gnuplot-mode for Emacs support.' |
24 |
has_version "${CATEGORY}/${PN}[emacs(-)]" && FORCE_PRINT_ELOG=1 |
25 |
+ |
26 |
+ # Make sure we don't mix build & host flags. |
27 |
+ sed -i \ |
28 |
+ -e 's:@CPPFLAGS@:$(BUILD_CPPFLAGS):' \ |
29 |
+ -e 's:@CFLAGS@:$(BUILD_CFLAGS):' \ |
30 |
+ -e 's:@LDFLAGS@:$(BUILD_LDFLAGS):' \ |
31 |
+ docs/Makefile.in || die |
32 |
} |
33 |
|
34 |
src_configure() { |
35 |
@@ -117,6 +124,8 @@ src_configure() { |
36 |
fi |
37 |
|
38 |
tc-export CC CXX #453174 |
39 |
+ tc-export_build_env BUILD_CC |
40 |
+ export CC_FOR_BUILD=${BUILD_CC} |
41 |
|
42 |
econf \ |
43 |
--without-pdf \ |
44 |
|
45 |
diff --git a/sci-visualization/gnuplot/gnuplot-5.0.1-r1.ebuild b/sci-visualization/gnuplot/gnuplot-5.0.1-r1.ebuild |
46 |
index ad5b62d..ed43ed5 100644 |
47 |
--- a/sci-visualization/gnuplot/gnuplot-5.0.1-r1.ebuild |
48 |
+++ b/sci-visualization/gnuplot/gnuplot-5.0.1-r1.ebuild |
49 |
@@ -104,6 +104,14 @@ src_prepare() { |
50 |
|
51 |
mv configure.in configure.ac || die |
52 |
eautoreconf |
53 |
+ |
54 |
+ # Make sure we don't mix build & host flags. |
55 |
+ sed -i \ |
56 |
+ -e 's:@CPPFLAGS@:$(BUILD_CPPFLAGS):' \ |
57 |
+ -e 's:@CFLAGS@:$(BUILD_CFLAGS):' \ |
58 |
+ -e 's:@LDFLAGS@:$(BUILD_LDFLAGS):' \ |
59 |
+ -e 's:@CC@:$(CC_FOR_BUILD):' \ |
60 |
+ docs/Makefile.in || die |
61 |
} |
62 |
|
63 |
src_configure() { |
64 |
@@ -117,6 +125,8 @@ src_configure() { |
65 |
fi |
66 |
|
67 |
tc-export CC CXX #453174 |
68 |
+ tc-export_build_env BUILD_CC |
69 |
+ export CC_FOR_BUILD=${BUILD_CC} |
70 |
|
71 |
econf \ |
72 |
--without-pdf \ |