public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: media-gfx/hp2xx/, media-gfx/hp2xx/files/
@ 2023-10-01  7:34 Sam James
  0 siblings, 0 replies; only message in thread
From: Sam James @ 2023-10-01  7:34 UTC (permalink / raw
  To: gentoo-commits

commit:     aa390cb06079d66e51dc8fccb9423ff6dd09fe4e
Author:     Brahmajit Das <brahmajit.xyz <AT> gmail <DOT> com>
AuthorDate: Fri Sep 22 15:31:24 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Oct  1 07:32:32 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=aa390cb0

media-gfx/hp2xx: Fix call to undeclared library function strcmp

Closes: https://bugs.gentoo.org/896218
Signed-off-by: Brahmajit Das <brahmajit.xyz <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/32996
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../hp2xx/files/hp2xx-3.4.4-clang16-build.patch    | 13 ++++
 media-gfx/hp2xx/hp2xx-3.4.4-r4.ebuild              | 84 ++++++++++++++++++++++
 2 files changed, 97 insertions(+)

diff --git a/media-gfx/hp2xx/files/hp2xx-3.4.4-clang16-build.patch b/media-gfx/hp2xx/files/hp2xx-3.4.4-clang16-build.patch
new file mode 100644
index 000000000000..20c8a143a6e3
--- /dev/null
+++ b/media-gfx/hp2xx/files/hp2xx-3.4.4-clang16-build.patch
@@ -0,0 +1,13 @@
+Bug: https://bugs.gentoo.org/896218
+--- a/sources/getopt.c
++++ b/sources/getopt.c
+@@ -22,6 +22,9 @@
+    along with this program; if not, write to the Free Software
+    Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
++
++#include <string.h>
++
+ \f
+ /**
+  ** Additions / fixes for hp2xx

diff --git a/media-gfx/hp2xx/hp2xx-3.4.4-r4.ebuild b/media-gfx/hp2xx/hp2xx-3.4.4-r4.ebuild
new file mode 100644
index 000000000000..c71fb1376d07
--- /dev/null
+++ b/media-gfx/hp2xx/hp2xx-3.4.4-r4.ebuild
@@ -0,0 +1,84 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+DESCRIPTION="Convert Hewlett-Packard's HP-GL plotter language to other graphics formats"
+HOMEPAGE="https://www.gnu.org/software/hp2xx/"
+SRC_URI="mirror://gnu/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="jpeg png tiff X"
+
+RDEPEND="
+	jpeg? ( media-libs/libjpeg-turbo:= )
+	png? (
+		media-libs/libpng:=
+		sys-libs/zlib
+	)
+	tiff? ( media-libs/tiff:= )
+	X? ( x11-libs/libX11 )"
+DEPEND="${RDEPEND}"
+BDEPEND="sys-apps/texinfo"
+
+PATCHES=(
+	"${FILESDIR}"/${P}-r1.patch
+	"${FILESDIR}"/${P}-docbuild.patch
+	"${FILESDIR}"/${P}-clang16-build.patch
+)
+
+src_prepare() {
+	default
+	cp -v makes/generic.mak sources/Makefile || die
+}
+
+src_configure() {
+	export PREVIEWER="no_prev"
+	export EX_SRC=
+	export EX_OBJ=
+	export EX_DEFS=-DUNIX
+	export ALL_LIBS=-lm
+
+	use jpeg && \
+		EX_SRC+=" to_jpg.c" \
+		EX_OBJ+=" to_jpg.o" \
+		EX_DEFS+=" -DJPG" \
+		ALL_LIBS+=" -ljpeg"
+	use png && \
+		EX_SRC+=" png.c to_png.c" \
+		EX_OBJ+=" png.o to_png.o" \
+		EX_DEFS+=" -DPNG" \
+		ALL_LIBS+=" -lpng"
+	use tiff && \
+		EX_SRC+=" to_tif.c" \
+		EX_OBJ+=" to_tif.o" \
+		EX_DEFS+=" -DTIF" \
+		ALL_LIBS+=" -ltiff"
+	use X && \
+		PREVIEWER="to_x11" \
+		EX_DEFS="-DHAS_UNIX_X11" \
+		ALL_LIBS+=" -lX11"
+
+	tc-export CC
+}
+
+src_compile() {
+	emake -C sources all
+}
+
+src_install() {
+	dodir \
+		/usr/bin \
+		/usr/share/info \
+		/usr/share/man/man1
+
+	emake \
+		prefix="${ED}"/usr \
+		mandir="${ED}"/usr/share/man \
+		infodir="${ED}"/usr/share/info \
+		install
+}


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2023-10-01  7:35 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-01  7:34 [gentoo-commits] repo/gentoo:master commit in: media-gfx/hp2xx/, media-gfx/hp2xx/files/ Sam James

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox