commit:     83759acc9db70f1795e9ce54e8869afd874673f1
Author:     Benda Xu <heroxbd <AT> gentoo <DOT> org>
AuthorDate: Mon Dec 16 12:32:50 2019 +0000
Commit:     Benda XU <heroxbd <AT> gentoo <DOT> org>
CommitDate: Mon Dec 16 14:04:15 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=83759acc

dev-util/cmt: Respect environment CXXFLAGS and LDFLAGS.

Package-Manager: Portage-2.3.79, Repoman-2.3.18
Signed-off-by: Benda Xu <heroxbd <AT> gentoo.org>

 dev-util/cmt/cmt-1.26_p20160527.ebuild             |  2 ++
 .../cmt/files/cmt-1.26_p20160527-ldflags.patch     | 29 ++++++++++++++++++++++
 2 files changed, 31 insertions(+)

diff --git a/dev-util/cmt/cmt-1.26_p20160527.ebuild 
b/dev-util/cmt/cmt-1.26_p20160527.ebuild
index 71772dec621..edf78928351 100644
--- a/dev-util/cmt/cmt-1.26_p20160527.ebuild
+++ b/dev-util/cmt/cmt-1.26_p20160527.ebuild
@@ -22,6 +22,8 @@ RDEPEND="${DEPEND}
 
 S="${WORKDIR}/CMT/${CMT_PV}"
 
+PATCHES=( "${FILESDIR}"/${PN}-1.26_p20160527-ldflags.patch )
+
 src_configure() {
        cd "${S}"/mgr || die
        ./INSTALL || die

diff --git a/dev-util/cmt/files/cmt-1.26_p20160527-ldflags.patch 
b/dev-util/cmt/files/cmt-1.26_p20160527-ldflags.patch
new file mode 100644
index 00000000000..e2491724938
--- /dev/null
+++ b/dev-util/cmt/files/cmt-1.26_p20160527-ldflags.patch
@@ -0,0 +1,29 @@
+--- a/mgr/requirements 2014-01-06 22:40:25.000000000 +0800
++++ b/mgr/requirements 2019-12-09 22:33:53.375723322 +0800
+@@ -157,7 +157,7 @@
+ macro cdebugflags     "" \
+       debug           "$(debug_option)"
+ 
+-macro cflags          "" \
++macro cflags          "${CFLAGS}" \
+       LynxOS-VGPW2    "-X" \
+       insure          "-std1" \
+       HP-UX           "+Z" \
+@@ -252,7 +252,7 @@
+       hp700_ux101     "-fpic" \
+       HP-UX           "+Z -Wc,-ansi_for_scope,on" \
+       hp_ux102        "-z +p -Wc,-ansi_for_scope,on +O2 +Onoinitcheck" \
+-      Linux           "-pipe -ansi -pedantic -W -Wall -Wwrite-strings 
-Wpointer-arith -Woverloaded-virtual " \
++      Linux           "${CXXFLAGS}" \
+       SunOS           "-KPIC" \
+       VisualC         '/nologo /DWIN32 /MD /W3 $(includes) /c /EHsc'
+ 
+@@ -403,7 +403,7 @@
+ macro shlibflags    "" \
+       HP-UX         "-Wl,-a,shared -b +Z -q -Wl,+s -Wl,+vallcompatwarnings" \
+       OSF1          "-shared -expect_unresolved '*'" \
+-      Linux         "-shared" \
++      Linux         "-shared ${LDFLAGS}" \
+       CYGWIN        "-shared" \
+       SunOS         "$(debug_option)" \
+       VisualC       "" \

Reply via email to