commit: c65e2baaad254759db44a4fce91c89750202b586
Author: David Seifert gentoo org>
AuthorDate: Sun Nov 20 23:55:50 2022 +
Commit: David Seifert gentoo org>
CommitDate: Sun Nov 20 23:55:50 2022 +
URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c65e2baa
app-text/pspresent: update EAPI 6 -> 8
Signed-off-by: David Seifert gentoo.org>
.../pspresent/files/pspresent-1.3-makefile.patch | 39 ++
...esent-1.3-r1.ebuild => pspresent-1.3-r2.ebuild} | 34 ---
2 files changed, 53 insertions(+), 20 deletions(-)
diff --git a/app-text/pspresent/files/pspresent-1.3-makefile.patch
b/app-text/pspresent/files/pspresent-1.3-makefile.patch
new file mode 100644
index ..363a52c57285
--- /dev/null
+++ b/app-text/pspresent/files/pspresent-1.3-makefile.patch
@@ -0,0 +1,39 @@
+--- a/Makefile
b/Makefile
+@@ -4,28 +4,16 @@
+ #
+
+ # You may need to change these paths
+-X11_CFLAGS=-I/usr/X11R6/include
+-X11_LDLIBS=-L/usr/X11R6/lib -lX11
++X11_CFLAGS = $(shell $(PKG_CONFIG) --cflags x11)
++X11_LDLIBS = $(shell $(PKG_CONFIG) --libs x11)
+
+ # Remove the following two lines to disable XINERAMA support
+-XINERAMA_CFLAGS=-DHAVE_LIBXINERAMA
+-XINERAMA_LDLIBS=-lXext -lXinerama
++ifdef USE_XINERAMA
++XINERAMA_CFLAGS = -DHAVE_LIBXINERAMA $(shell $(PKG_CONFIG) --cflags xinerama)
++XINERAMA_LDLIBS = $(shell $(PKG_CONFIG) --libs xinerama)
++endif
+
+-CC = gcc
+-CFLAGS = -Wall -O2 $(X11_CFLAGS) $(XINERAMA_CFLAGS)
++CPPFLAGS += $(X11_CFLAGS) $(XINERAMA_CFLAGS)
+ LDLIBS = $(X11_LDLIBS) $(XINERAMA_LDLIBS)
+
+-TARGET = pspresent
+-OBJS = pspresent.o gs.o ps.o
+-
+-$(TARGET): $(OBJS)
+- $(CC) -o $(TARGET) $(OBJS) $(LDLIBS)
+-
+-clean:
+- rm $(TARGET) $(OBJS)
+-
+-.SUFFIXES:
+-.SUFFIXES: .c .o
+-
+-.c.o:
+- $(CC) $(CFLAGS) -o $@ -c $<
++pspresent: gs.o ps.o
diff --git a/app-text/pspresent/pspresent-1.3-r1.ebuild
b/app-text/pspresent/pspresent-1.3-r2.ebuild
similarity index 57%
rename from app-text/pspresent/pspresent-1.3-r1.ebuild
rename to app-text/pspresent/pspresent-1.3-r2.ebuild
index 24ed68ea8e0b..167d8e647c8a 100644
--- a/app-text/pspresent/pspresent-1.3-r1.ebuild
+++ b/app-text/pspresent/pspresent-1.3-r2.ebuild
@@ -1,38 +1,32 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
+EAPI=8
inherit toolchain-funcs
DESCRIPTION="A tool to display full-screen PostScript presentations"
-SRC_URI="http://www.cse.unsw.edu.au/~matthewc/pspresent/${P}.tar.gz";
HOMEPAGE="http://www.cse.unsw.edu.au/~matthewc/pspresent/";
-SLOT="0"
-LICENSE="GPL-2"
+SRC_URI="http://www.cse.unsw.edu.au/~matthewc/pspresent/${P}.tar.gz";
-IUSE="xinerama"
+LICENSE="GPL-2"
+SLOT="0"
KEYWORDS="amd64 ppc x86"
+IUSE="xinerama"
-RDEPEND="x11-libs/libX11
- xinerama? ( x11-libs/libXinerama )
- app-text/ghostscript-gpl"
+RDEPEND="
+ app-text/ghostscript-gpl
+ x11-libs/libX11
+ xinerama? ( x11-libs/libXinerama )"
DEPEND="${RDEPEND}
x11-base/xorg-proto"
+BDEPEND="virtual/pkgconfig"
-src_prepare() {
- default
- if ! use xinerama ; then
- sed -i -e "/^XINERAMA/s/^/#/g" Makefile || die "sed Makefile"
- fi
- sed -i Makefile \
- -e 's|= -Wall -O2|+= -Wall|g' \
- -e 's| -o | $(LDFLAGS)&|g' \
- || die "sed Makefile"
-}
+PATCHES=( "${FILESDIR}"/${P}-makefile.patch )
-src_compile() {
- emake CC="$(tc-getCC)"
+src_configure() {
+ tc-export CC PKG_CONFIG
+ use xinerama && export USE_XINERAMA=1
}
src_install() {