summaryrefslogtreecommitdiff
path: root/dev-cpp/libmcpp
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-03-19 06:50:06 +0000
committerV3n3RiX <venerix@koprulu.sector>2024-03-19 06:50:06 +0000
commit06617f385b21ef2262c88f17869c15c424e67d21 (patch)
tree3f6ea6fba81d85145b37641fb93140f3c70f57c9 /dev-cpp/libmcpp
parent2c18b7f7fb2885d27960657c60906ef0bac0681e (diff)
gentoo auto-resync : 19:03:2024 - 06:50:06
Diffstat (limited to 'dev-cpp/libmcpp')
-rw-r--r--dev-cpp/libmcpp/Manifest3
-rw-r--r--dev-cpp/libmcpp/files/libmcpp-2.7.2-incompatible-pointer-types.patch26
-rw-r--r--dev-cpp/libmcpp/files/mcpp-c99.patch59
-rw-r--r--dev-cpp/libmcpp/libmcpp-2.7.2_p5-r2.ebuild48
4 files changed, 136 insertions, 0 deletions
diff --git a/dev-cpp/libmcpp/Manifest b/dev-cpp/libmcpp/Manifest
index 9da6c791ecc3..64763cb8f2cf 100644
--- a/dev-cpp/libmcpp/Manifest
+++ b/dev-cpp/libmcpp/Manifest
@@ -1,6 +1,9 @@
AUX libmcpp-2.7.2-fix-build-system.patch 1008 BLAKE2B d9a87af2faada430c9bd09bb6d4e70f51385725b45dd380b6eecd67e82ed6f2e001f3768b03e08864055fe4119187cf26efd3f09463c64072a9647f63ad251d1 SHA512 25e2e9cd8d18080947a84c0d76f0b34d74b289ccc7c6172278908c026dd6f7379ebb268aae79c3e8ab458f3883aa212e54a137cbaab336c1277acdad07a13a01
AUX libmcpp-2.7.2-fix-configure-checks.patch 1056 BLAKE2B 94dddb9fb10f9cbab18dd08a02ae15816f3cff4e7d8f2331114f02b817a2c69f509ced868c7c8e7d46e45bad44bbf922026383672865b50c3981fbe40633f116 SHA512 5b1eaba11112e37cbc5a635f872d5a749948573f413758c312485dace26e7c563dc5ea35e5029c105fb6a24000a3b79b5e4b49f99e3bc54cbe7263d355ad0744
+AUX libmcpp-2.7.2-incompatible-pointer-types.patch 1003 BLAKE2B 4da1ab72e1ece8850ee2cb34e530a44d2f986d22df22dd4d15c67b72ceb4f3f46ae1491ca7de47903a644589a74122e5c9d2a1f07a3a2793b6f6aed059363671 SHA512 dadc31b36d2c775273ea271d440a56abc5fdccb5a3d682b3f660c24a1bd4c7e2d0853675bfdd40f111622215323d78dff1f1f588c1948a4fa5b1fe063f79a783
+AUX mcpp-c99.patch 1874 BLAKE2B 75e3c31435b6e61d47bbd46c81098d01659ad168308d4b31503cb553efbe525b925feb112bd549dea1138fcd8003633f3a64af57c300c6d89519fa61f3d55944 SHA512 73f0d07bb97b040f91f3c34a60c2275a6752a5cdd77f17982aaa1c68ab15f9052f2f69e916dc9a526853a5b5216d7edd63a987bf8a6ed3e99c14ac4e662e8b95
DIST mcpp-2.7.2.tar.gz 1533457 BLAKE2B 4368fd1c667923ab3b60ce79f8421c549a9d9105957ca87b9ba49be513cb1be7f220a3ddbaf306e860014d5211af480d07170d912d3d4a80345d8eab45fd6c00 SHA512 1ca885cb13fdb684de9d0595a9215b52f48a93a69077d82cdcacafe40d9a61fb77b00a3ff2b8890e7bc0a0fcc0c8d70d4093c00c280351cd4459aba67c573235
DIST mcpp_2.7.2-5.debian.tar.xz 7528 BLAKE2B 92f455809cfb49d97ca4e62c7087ebe2ebe0ce835e8f12d6e93b1df2ec1e15472f242637f320be2b6bada85b193545fcf3608e8c9a935805a5f052909d3c6f0b SHA512 08509945048ccc4525ecd61d3f901a4d81fe73c1db84c26b76664d5127970af45662a168b99836b58467afc7202a1a20e0dfe8954a87e4cd1368f2136d7955be
EBUILD libmcpp-2.7.2_p5-r1.ebuild 920 BLAKE2B 9d3ca87b04c9c65e4f99eeb3a71e0d2a7ae357bbeb209e682099617e54b7362b1b300909867b8c4a8d4fb4b31e75bfec173d6aaae2a5ec088e5ba3f2df4a72d2 SHA512 5a02262234f55f93be2aa47d346f2c01d07be91f721ac1797863821a6a4a0591c760649529dc5129aa88ad723b8c14e982f95e55f913c061b969ba671e96dc34
+EBUILD libmcpp-2.7.2_p5-r2.ebuild 1012 BLAKE2B c2269e2d2a828c070716bc0dd29726e4f092eb8a09257c98b64989f50794d935076d7b1698b883bed87fadf24cc96464e7d455404fa6808864b84d1d40ff82c6 SHA512 c9236332941cdcef59591b7aa4dbaa61150090cc898d51ccecd420aef0373ab3079eba36bd64ae5758c35a7d675c66344473638b7aa61800576adb950cb32fd7
MISC metadata.xml 242 BLAKE2B c3104b4c49aa49dc9855ea0b1469084d84e3c66395bd368859edefe22ff374525cc05752f56acc5e6976cda7564f54fc736d91019a143d74d5598bfad7595c41 SHA512 122762f21cf0e354a83c94569028bc356ab1af71727787d8bd1402a67690bf0a3a32ebd6304a249febfe942f5f0a1b1e2c07d81b31a05a8abae530e00c21e3e9
diff --git a/dev-cpp/libmcpp/files/libmcpp-2.7.2-incompatible-pointer-types.patch b/dev-cpp/libmcpp/files/libmcpp-2.7.2-incompatible-pointer-types.patch
new file mode 100644
index 000000000000..fc84009d4366
--- /dev/null
+++ b/dev-cpp/libmcpp/files/libmcpp-2.7.2-incompatible-pointer-types.patch
@@ -0,0 +1,26 @@
+https://github.com/jbrandwood/mcpp/commit/3b274fe8f31d61996343b17402f30408a6e447cf
+
+From 3b274fe8f31d61996343b17402f30408a6e447cf Mon Sep 17 00:00:00 2001
+From: John Brandwood <john.brandwood@telzey.com>
+Date: Fri, 15 Mar 2024 15:15:53 -0400
+Subject: [PATCH] Fix build with GCC 14.x by splitting a NULL assignment into 2
+ lines.
+
+---
+ src/expand.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/expand.c b/src/expand.c
+index 08f829a..ea2d2a9 100644
+--- a/src/expand.c
++++ b/src/expand.c
+@@ -710,7 +710,8 @@ static char * replace(
+ } else {
+ m_inf->locs.start_col = m_inf->locs.start_line = 0L;
+ }
+- m_inf->args = m_inf->loc_args = NULL; /* Default args */
++ m_inf->args = NULL; /* Default args */
++ m_inf->loc_args = NULL;
+ for (num = 1, recurs = 0; num < m_num; num++)
+ if (mac_inf[ num].defp == defp)
+ recurs++; /* Recursively nested macro */
diff --git a/dev-cpp/libmcpp/files/mcpp-c99.patch b/dev-cpp/libmcpp/files/mcpp-c99.patch
new file mode 100644
index 000000000000..e6538e7955f4
--- /dev/null
+++ b/dev-cpp/libmcpp/files/mcpp-c99.patch
@@ -0,0 +1,59 @@
+Florian Weimer's c99 patch from https://sourceforge.net/p/mcpp/patches/7/
+
+Do not define and undefine _*_SOURCE macros. These have special
+semantics to glibc. <limits.h> may include <features.h>, and which
+point the feature configuration gets frozen. Without this change,
+when system.c includes <unistd.h>, the feature macros are hard-coded
+as baseline POSIX, which does not include readlink. This will lead to
+compilation errors with future compilers.
+
+diff --git a/src/configed.H b/src/configed.H
+index b4d1ebf3a6bfa280..bde16fc8db38a2c4 100644
+--- a/src/configed.H
++++ b/src/configed.H
+@@ -295,20 +295,7 @@
+ * ULONGMAX should be defined to the ULONG_MAX in <limits.h>.
+ */
+
+-/* _POSIX_* only to get PATH_MAX */
+-#define _POSIX_ 1
+-#define _POSIX_SOURCE 1
+-#ifndef _POSIX_C_SOURCE
+-#define _POSIX_C_SOURCE 1
+-#define _POSIX_C_SOURCE_defined 1
+-#endif
+ #include "limits.h"
+-#undef _POSIX_
+-#undef _POSIX_SOURCE
+-#ifdef _POSIX_C_SOURCE_defined
+-#undef _POSIX_C_SOURCE
+-#undef _POSIX_C_SOURCE_defined
+-#endif
+ #define CHARBIT CHAR_BIT
+ #define UCHARMAX UCHAR_MAX
+ #define USHRTMAX USHRT_MAX
+diff --git a/src/noconfig.H b/src/noconfig.H
+index 6b634fe0b32ff67c..7c923c900c8865dd 100644
+--- a/src/noconfig.H
++++ b/src/noconfig.H
+@@ -570,20 +570,7 @@
+ #include "stdio.h"
+
+ /* PATHMAX is the maximum length of path-list on the host system. */
+-/* _POSIX_* only to get PATH_MAX */
+-#define _POSIX_ 1
+-#define _POSIX_SOURCE 1
+-#ifndef _POSIX_C_SOURCE
+-#define _POSIX_C_SOURCE 1
+-#define _POSIX_C_SOURCE_defined 1
+-#endif
+ #include "limits.h"
+-#undef _POSIX_
+-#undef _POSIX_SOURCE
+-#ifdef _POSIX_C_SOURCE_defined
+-#undef _POSIX_C_SOURCE
+-#undef _POSIX_C_SOURCE_defined
+-#endif
+ #ifdef PATH_MAX
+ #define PATHMAX PATH_MAX /* Posix macro */
+ #else
diff --git a/dev-cpp/libmcpp/libmcpp-2.7.2_p5-r2.ebuild b/dev-cpp/libmcpp/libmcpp-2.7.2_p5-r2.ebuild
new file mode 100644
index 000000000000..3d410d6d4019
--- /dev/null
+++ b/dev-cpp/libmcpp/libmcpp-2.7.2_p5-r2.ebuild
@@ -0,0 +1,48 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+MY_PN=${PN/lib/}
+MY_P=$(ver_cut 1-4 ${MY_PN}-${PV})
+
+DESCRIPTION="A portable C++ preprocessor"
+HOMEPAGE="http://mcpp.sourceforge.net"
+SRC_URI="mirror://sourceforge/mcpp/${MY_P}.tar.gz"
+SRC_URI+=" mirror://debian/pool/main/m/${MY_PN}/${MY_PN}_${PV/_p/-}.debian.tar.xz"
+S="${WORKDIR}"/${MY_P}
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~loong ~ppc64 ~riscv ~x86 ~x86-linux ~x64-macos"
+
+PATCHES=(
+ # bug #718808
+ "${WORKDIR}"/debian/patches/
+
+ "${FILESDIR}"/${PN}-2.7.2-fix-build-system.patch
+ "${FILESDIR}"/${PN}-2.7.2-fix-configure-checks.patch
+ "${FILESDIR}"/${PN}-2.7.2-incompatible-pointer-types.patch
+ "${FILESDIR}"/mcpp-c99.patch
+)
+
+src_prepare() {
+ default
+
+ # bug #778461
+ sed -i 's/-lmcpp/libmcpp.la/' src/Makefile.am || die
+
+ eautoreconf
+}
+
+src_configure() {
+ econf --enable-mcpplib
+}
+
+src_install() {
+ default
+
+ find "${ED}" -name '*.la' -delete || die
+}