Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Jan 2024 23:07:05 GMT
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 6d303173a5c3 - main - graphics/pho: the port had been modernized (+)
Message-ID:  <202401222307.40MN75q3085350@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by danfe:

URL: https://cgit.FreeBSD.org/ports/commit/?id=6d303173a5c3ef91a43a7dc076e760dd3e126c93

commit 6d303173a5c3ef91a43a7dc076e760dd3e126c93
Author:     Alexey Dokuchaev <danfe@FreeBSD.org>
AuthorDate: 2024-01-22 23:06:28 +0000
Commit:     Alexey Dokuchaev <danfe@FreeBSD.org>
CommitDate: 2024-01-22 23:06:28 +0000

    graphics/pho: the port had been modernized (+)
    
    - Convert somewhat cluttered `post-patch' target to a regular patch
    - Install the manpage under ${PREFIX}/share/man per new world order
    - Chase HTTP/1.1 301 Moved Permanently redirect in the MASTER_SITES
---
 graphics/pho/Makefile             |  9 ++-------
 graphics/pho/files/patch-Makefile | 22 ++++++++++++++++++++++
 2 files changed, 24 insertions(+), 7 deletions(-)

diff --git a/graphics/pho/Makefile b/graphics/pho/Makefile
index bd8cbe8d7c24..e492d0283015 100644
--- a/graphics/pho/Makefile
+++ b/graphics/pho/Makefile
@@ -2,7 +2,7 @@ PORTNAME=	pho
 PORTVERSION=	1.0
 PORTREVISION=	1
 CATEGORIES=	graphics
-MASTER_SITES=	http://shallowsky.com/software/pho/
+MASTER_SITES=	${WWW}
 
 MAINTAINER=	danfe@FreeBSD.org
 COMMENT=	Lightweight image viewer
@@ -12,17 +12,12 @@ LICENSE=	GPLv2
 
 USES=		gmake gnome pkgconfig
 USE_GNOME=	gtk20
-MAKE_ARGS=	INSTALLPREFIX="${STAGEDIR}${PREFIX}"
 ALL_TARGET=	${PORTNAME}
 WRKSRC=		${WRKDIR}/${PORTNAME}
 
-PLIST_FILES=	bin/${PORTNAME} man/man1/${PORTNAME}.1.gz
+PLIST_FILES=	bin/${PORTNAME} share/man/man1/${PORTNAME}.1.gz
 
 post-patch:
-	@${REINPLACE_CMD} -e 's|make|$$(MAKE)| ; \
-		/bin/s|$$(INSTALL)|${INSTALL_PROGRAM}| ; \
-		/man/s|$$(INSTALL)|${INSTALL_MAN}| ; \
-		/CFLAGS/s|-g ||' ${WRKSRC}/Makefile
 	@${REINPLACE_CMD} -e 's|-Wall -g -O2 ||' ${WRKSRC}/exif/Makefile
 
 .include <bsd.port.mk>
diff --git a/graphics/pho/files/patch-Makefile b/graphics/pho/files/patch-Makefile
new file mode 100644
index 000000000000..80202ca0ddd7
--- /dev/null
+++ b/graphics/pho/files/patch-Makefile
@@ -0,0 +1,22 @@
+--- Makefile.orig	2020-09-26 16:16:24 UTC
++++ Makefile
+@@ -4,7 +4,7 @@ VERSION = 1.0
+ 
+ # Locate the gtk/gdk libraries (thanks to nev for this!)
+ GTKFLAGS := $(shell pkg-config --cflags gtk+-2.0 gdk-2.0 2> /dev/null)
+-CFLAGS += -g -Wall -pedantic -DVERSION='"$(VERSION)"' $(GTKFLAGS)
++CFLAGS += -Wall -pedantic -DVERSION='"$(VERSION)"' $(GTKFLAGS)
+ 
+ XLIBS := $(shell pkg-config --libs gtk+-2.0 > /dev/null)
+ GLIBS := $(shell pkg-config --libs gtk+-2.0 gdk-2.0)
+@@ -57,8 +57,8 @@ deb: pho
+ 	dpkg-buildpackage -rfakeroot
+ 
+ install: pho
+-	$(INSTALL) pho $(INSTALLPREFIX)/bin/pho
+-	$(INSTALL) doc/pho.1 $(INSTALLPREFIX)/man/man1/pho.1
++	$(BSD_INSTALL_PROGRAM) pho $(DESTDIR)$(PREFIX)/bin
++	$(BSD_INSTALL_MAN) doc/pho.1 $(DESTDIR)$(PREFIX)/share/man/man1
+ 
+ clean:
+ 	rm -f *.[oas] *.ld core* pho pho-*.tar.gz *.rpm *.tar.gz



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202401222307.40MN75q3085350>