From cc40eb6f345c1193e853cb752bc8b727d6602e53 Mon Sep 17 00:00:00 2001 From: Sam James Date: Fri, 4 Nov 2022 05:09:18 +0000 Subject: app-text/dvisvgm: fix configure w/ clang 16 Signed-off-by: Sam James --- app-text/dvisvgm/dvisvgm-2.14-r1.ebuild | 65 ++++++++++++++++++++++ app-text/dvisvgm/dvisvgm-2.14.ebuild | 55 ------------------ .../files/dvisvgm-2.14-configure-clang16.patch | 22 ++++++++ 3 files changed, 87 insertions(+), 55 deletions(-) create mode 100644 app-text/dvisvgm/dvisvgm-2.14-r1.ebuild delete mode 100644 app-text/dvisvgm/dvisvgm-2.14.ebuild create mode 100644 app-text/dvisvgm/files/dvisvgm-2.14-configure-clang16.patch (limited to 'app-text') diff --git a/app-text/dvisvgm/dvisvgm-2.14-r1.ebuild b/app-text/dvisvgm/dvisvgm-2.14-r1.ebuild new file mode 100644 index 000000000000..7c440a044d8a --- /dev/null +++ b/app-text/dvisvgm/dvisvgm-2.14-r1.ebuild @@ -0,0 +1,65 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools + +DESCRIPTION="Converts DVI files to SVG" +HOMEPAGE="https://dvisvgm.de/" +SRC_URI="https://github.com/mgieseki/dvisvgm/releases/download/${PV}/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~ppc-macos ~x64-macos" +IUSE="test" + +# Tests don't work from ${WORKDIR}: kpathsea tries to search in relative +# directories from where the binary is executed. +# We cannot really use absolute paths in the kpathsea configuration since that +# would make it harder for prefix installs. +RESTRICT="test" + +RDEPEND=" + >=app-arch/brotli-1.0.5:= + app-text/ghostscript-gpl:= + dev-libs/kpathsea:= + dev-libs/openssl:= + >=dev-libs/xxhash-0.8.1 + >=media-gfx/potrace-1.10-r1 + media-libs/freetype:2 + >=media-libs/woff2-1.0.2 + sys-libs/zlib + virtual/tex-base +" +DEPEND=" + ${RDEPEND} + test? ( >=dev-cpp/gtest-1.11 ) +" +BDEPEND=" + app-text/asciidoc + app-text/xmlto + dev-libs/libxslt + virtual/pkgconfig +" + +PATCHES=( + "${FILESDIR}"/${P}-ghostscript.patch + "${FILESDIR}"/${P}-Add-missing-cstdint-includes-for-GCC-13.patch + "${FILESDIR}"/${PN}-2.14-configure-clang16.patch +) + +src_prepare() { + default + + # Drop once configure patch merged for clang 16 + eautoreconf +} + +src_configure() { + local myargs=( + --without-ttfautohint + ) + + econf "${myargs[@]}" +} diff --git a/app-text/dvisvgm/dvisvgm-2.14.ebuild b/app-text/dvisvgm/dvisvgm-2.14.ebuild deleted file mode 100644 index 7a3027f6d6e0..000000000000 --- a/app-text/dvisvgm/dvisvgm-2.14.ebuild +++ /dev/null @@ -1,55 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DESCRIPTION="Converts DVI files to SVG" -HOMEPAGE="https://dvisvgm.de/" -SRC_URI="https://github.com/mgieseki/dvisvgm/releases/download/${PV}/${P}.tar.gz" - -LICENSE="GPL-3" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~ppc-macos ~x64-macos" -IUSE="test" - -# Tests don't work from ${WORKDIR}: kpathsea tries to search in relative -# directories from where the binary is executed. -# We cannot really use absolute paths in the kpathsea configuration since that -# would make it harder for prefix installs. -RESTRICT="test" - -RDEPEND=" - >=app-arch/brotli-1.0.5:= - app-text/ghostscript-gpl:= - dev-libs/kpathsea:= - dev-libs/openssl:= - >=dev-libs/xxhash-0.8.1 - >=media-gfx/potrace-1.10-r1 - media-libs/freetype:2 - >=media-libs/woff2-1.0.2 - sys-libs/zlib - virtual/tex-base -" -DEPEND=" - ${RDEPEND} - test? ( >=dev-cpp/gtest-1.11 ) -" -BDEPEND=" - app-text/asciidoc - app-text/xmlto - dev-libs/libxslt - virtual/pkgconfig -" - -PATCHES=( - "${FILESDIR}"/${P}-ghostscript.patch - "${FILESDIR}"/${PN}-2.14-Add-missing-cstdint-includes-for-GCC-13.patch -) - -src_configure() { - local myargs=( - --without-ttfautohint - ) - - econf "${myargs[@]}" -} diff --git a/app-text/dvisvgm/files/dvisvgm-2.14-configure-clang16.patch b/app-text/dvisvgm/files/dvisvgm-2.14-configure-clang16.patch new file mode 100644 index 000000000000..6fe679f551d1 --- /dev/null +++ b/app-text/dvisvgm/files/dvisvgm-2.14-configure-clang16.patch @@ -0,0 +1,22 @@ +https://github.com/mgieseki/dvisvgm/pull/200 + +From e3cfc0976ec1f5bbcd389c318eabc2a783990de0 Mon Sep 17 00:00:00 2001 +From: Sam James +Date: Fri, 4 Nov 2022 05:07:09 +0000 +Subject: [PATCH] configure.ac: fix -Wimplicit-function-declaration + +Clang 16 makes -Wimplicit-function-declaration an error by default. We +need to include for exit(). + +Signed-off-by: Sam James +--- a/configure.ac ++++ b/configure.ac +@@ -55,6 +55,7 @@ AC_CHECK_LIB([kpathsea], [kpse_find_file],, + + AC_MSG_CHECKING([kpathsea version]) + AC_RUN_IFELSE([AC_LANG_SOURCE([#include ++ #include + #include + int main() { + FILE *f; + -- cgit v1.2.3-65-gdbad