diff options
author | Eli Schwartz <eschwartz93@gmail.com> | 2024-02-29 16:47:26 -0500 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2024-02-29 23:57:38 +0000 |
commit | dac60e2edf21449587edf8cf996a01416061a1d3 (patch) | |
tree | 144bd7f082ef5500cbe1ddfea88828907a696cdf /app-text | |
parent | media-libs/fdk-aac: filter LTO (ODR violations) (diff) | |
download | gentoo-dac60e2edf21449587edf8cf996a01416061a1d3.tar.gz gentoo-dac60e2edf21449587edf8cf996a01416061a1d3.tar.bz2 gentoo-dac60e2edf21449587edf8cf996a01416061a1d3.zip |
app-text/mecab: fix totally broken approach to fixing configure CFLAGS
Instead of sed'ing in the current CFLAGS, remove the broken code. This
is actually technically correct and can be applied by others, and it
also means that flag-o-matic doesn't get silently ignored because the
flags were previously baked into the raw file.
Signed-off-by: Eli Schwartz <eschwartz93@gmail.com>
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'app-text')
-rw-r--r-- | app-text/mecab/files/0001-configure-remove-terrible-horrible-code-that-resets-.patch | 33 | ||||
-rw-r--r-- | app-text/mecab/mecab-0.996-r1.ebuild | 5 | ||||
-rw-r--r-- | app-text/mecab/mecab-0.996-r2.ebuild | 5 |
3 files changed, 35 insertions, 8 deletions
diff --git a/app-text/mecab/files/0001-configure-remove-terrible-horrible-code-that-resets-.patch b/app-text/mecab/files/0001-configure-remove-terrible-horrible-code-that-resets-.patch new file mode 100644 index 000000000000..a5cc60335209 --- /dev/null +++ b/app-text/mecab/files/0001-configure-remove-terrible-horrible-code-that-resets-.patch @@ -0,0 +1,33 @@ +From 8ddfa1e8c274759f287c9ee73d4d1625028c3bb8 Mon Sep 17 00:00:00 2001 +From: Eli Schwartz <eschwartz93@gmail.com> +Date: Thu, 29 Feb 2024 16:44:27 -0500 +Subject: [PATCH] configure: remove terrible horrible code that resets CFLAGS + to "-O3" + +... and totally ignores all user defined flags. +--- + configure.in | 8 -------- + 1 file changed, 8 deletions(-) + +diff --git a/configure.in b/configure.in +index a5e2a5e..4ac75c1 100644 +--- a/configure.in ++++ b/configure.in +@@ -85,14 +85,6 @@ else + fi + fi + +-dnl +-dnl check gcc +-dnl +-if test -n "$GCC"; then +- CFLAGS="-O3 -Wall " +- CXXFLAGS="-O3 -Wall " +-fi +- + dnl + dnl check Char Code + dnl +-- +2.43.0 + diff --git a/app-text/mecab/mecab-0.996-r1.ebuild b/app-text/mecab/mecab-0.996-r1.ebuild index 9eb02cee3b92..3e419f7d4581 100644 --- a/app-text/mecab/mecab-0.996-r1.ebuild +++ b/app-text/mecab/mecab-0.996-r1.ebuild @@ -30,16 +30,13 @@ PDEPEND=" PATCHES=( "${FILESDIR}"/${PN}-0.98-iconv.patch "${FILESDIR}"/${PN}-0.996-clang-16-register.patch + "${FILESDIR}"/0001-configure-remove-terrible-horrible-code-that-resets-.patch ) HTML_DOCS=( doc/. ) src_prepare() { default - sed -i \ - -e "/CFLAGS/s/-O3/${CFLAGS}/" \ - -e "/CXXFLAGS/s/-O3/${CXXFLAGS}/" \ - configure.in sed -i "s:/lib:/$(get_libdir):" ${PN}rc.in mv configure.{in,ac} || die diff --git a/app-text/mecab/mecab-0.996-r2.ebuild b/app-text/mecab/mecab-0.996-r2.ebuild index 078cd4f66a9d..11c5322f3ecf 100644 --- a/app-text/mecab/mecab-0.996-r2.ebuild +++ b/app-text/mecab/mecab-0.996-r2.ebuild @@ -31,16 +31,13 @@ PATCHES=( "${FILESDIR}"/${PN}-0.98-iconv.patch "${FILESDIR}"/${PN}-0.996-clang-16-register.patch "${FILESDIR}"/${PN}-0.996-clang-16-binary_function.patch + "${FILESDIR}"/0001-configure-remove-terrible-horrible-code-that-resets-.patch ) HTML_DOCS=( doc/. ) src_prepare() { default - sed -i \ - -e "/CFLAGS/s/-O3/${CFLAGS}/" \ - -e "/CXXFLAGS/s/-O3/${CXXFLAGS}/" \ - configure.in sed -i "s:/lib:/$(get_libdir):" ${PN}rc.in mv configure.{in,ac} || die |