View | Details | Raw Unified | Return to bug 226535
Collapse All | Expand All

(-)./Makefile (-3 / +15 lines)
Lines 1-13 Link Here
1
# $FreeBSD: head/misc/owrep/Makefile 454323 2017-11-16 18:41:01Z yuri $
1
# $FreeBSD: head/misc/owrep/Makefile 454323 2017-11-16 18:41:01Z yuri $
2
2
3
PORTNAME=	owrep
3
PORTNAME=	owrep
4
DISTVERSION=	1.1
4
DISTVERSION=	1.2
5
CATEGORIES=	misc
5
CATEGORIES=	misc
6
MASTER_SITES=	http://www.ml1.org.uk/distfiles/ \
6
MASTER_SITES=	http://www.ml1.org.uk/distfiles/ \
7
		http://www.ancientgeek.org.uk/distfiles/
7
		http://www.ancientgeek.org.uk/distfiles/
8
8
9
MAINTAINER=	bob@eager.cx
9
MAINTAINER=	bob@eager.cx
10
COMMENT=	Weather reporting program based on openweathermap.org
10
COMMENT=	Weather reporting program using openweathermap.org
11
11
12
LICENSE=	BSD3CLAUSE
12
LICENSE=	BSD3CLAUSE
13
13
Lines 15-18 Link Here
15
15
16
USES=		localbase:ldflags zip
16
USES=		localbase:ldflags zip
17
17
18
.include <bsd.port.mk>
18
post-patch:
19
		@${REINPLACE_CMD} 's|%%PREFIX%%|${PREFIX}|' ${WRKSRC}/owrep.c
20
		@${REINPLACE_CMD} 's|%%PREFIX%%|${PREFIX}|' ${WRKSRC}/owrep.1
21
22
.include <bsd.port.pre.mk>
23
24
do-install:
25
		${INSTALL_PROGRAM} ${WRKSRC}/owrep ${STAGEDIR}${PREFIX}/bin
26
		${INSTALL_MAN} ${WRKSRC}/owrep.1 ${STAGEDIR}${PREFIX}/man/man1
27
		${INSTALL_MAN} ${WRKSRC}/owrep.conf.5 ${STAGEDIR}${PREFIX}/man/man5
28
		${INSTALL_DATA} ${WRKSRC}/owrep.conf.sample ${STAGEDIR}${PREFIX}/etc
29
30
.include <bsd.port.post.mk>
(-)./distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1508972794
1
TIMESTAMP = 1520377345
2
SHA256 (owrep-1.1.zip) = 53e3ac6951b59619d817230cbf5f514961911ad625bfec4922094189963dfc0a
2
SHA256 (owrep-1.2.zip) = bd4b91cb7699c24dd2f58416b0973395eed2c701678dca24bb523e14003cee5e
3
SIZE (owrep-1.1.zip) = 21700
3
SIZE (owrep-1.2.zip) = 21747
(-)./files/patch-Makefile (-18 / +13 lines)
Lines 1-6 Link Here
1
--- Makefile.orig	2017-05-30 23:54:30 UTC
1
--- Makefile.orig	2018-03-04 22:14:18 UTC
2
+++ Makefile
2
+++ Makefile
3
@@ -5,10 +5,10 @@
3
@@ -5,11 +5,6 @@
4
 #
4
 #
5
 CC?=		clang
5
 CC?=		clang
6
 #
6
 #
Lines 8-21 Link Here
8
-INSTALL_MAN1=	/usr/local/man/man1
8
-INSTALL_MAN1=	/usr/local/man/man1
9
-INSTALL_MAN5=	/usr/local/man/man5
9
-INSTALL_MAN5=	/usr/local/man/man5
10
-INSTALL_ETC=	/usr/local/etc
10
-INSTALL_ETC=	/usr/local/etc
11
+INSTALL_TO =	$(DESTDIR)/$(PREFIX)/bin
11
-#
12
+INSTALL_MAN1=	$(DESTDIR)/$(PREFIX)/man/man1
13
+INSTALL_MAN5=	$(DESTDIR)/$(PREFIX)/man/man5
14
+INSTALL_ETC=	$(DESTDIR)/$(PREFIX)/etc
15
 #
16
 PRODUCT =	owrep
12
 PRODUCT =	owrep
17
 #
13
 #
18
@@ -38,7 +38,7 @@ CFLAGS+=	-O2 $(COMFLAGS) -I /usr/local/i
14
 SRC =		owrep.c config.c extract.c lookup.c massage.c netio.c output.c
15
@@ -38,20 +33,11 @@ CFLAGS+=	-O2 $(COMFLAGS) -I /usr/local/i
19
 all:		$(PRODUCT)
16
 all:		$(PRODUCT)
20
 #
17
 #
21
 $(PRODUCT):	$(OBJ)
18
 $(PRODUCT):	$(OBJ)
Lines 24-41 Link Here
24
 #
21
 #
25
 depend:
22
 depend:
26
 		mkdep $(CFLAGS) $(SRC)
23
 		mkdep $(CFLAGS) $(SRC)
27
@@ -46,10 +46,10 @@ depend:
24
 #
28
 install:	$(PRODUCT)
25
-install:	$(PRODUCT)
29
 		gzip -f -k $(MAN1)
26
-		gzip -f -k $(MAN1)
30
 		gzip -f -k $(MAN5)
27
-		gzip -f -k $(MAN5)
31
-		install -s -g wheel -o root $(PRODUCT) $(INSTALL_TO)
28
-		install -s -g wheel -o root $(PRODUCT) $(INSTALL_TO)
32
-		install -g wheel -o root $(MAN1).gz $(INSTALL_MAN1)
29
-		install -g wheel -o root $(MAN1).gz $(INSTALL_MAN1)
33
-		install -g wheel -o root $(MAN5).gz $(INSTALL_MAN5)
30
-		install -g wheel -o root $(MAN5).gz $(INSTALL_MAN5)
34
-		install -g wheel -o root $(CONF) $(INSTALL_ETC)
31
-		install -g wheel -o root $(CONF) $(INSTALL_ETC)
35
+		install -s $(PRODUCT) $(INSTALL_TO)
32
-		rm -f $(MAN1).gz $(MAN5).gz
36
+		install $(MAN1).gz $(INSTALL_MAN1)
33
-#
37
+		install $(MAN5).gz $(INSTALL_MAN5)
38
+		install $(CONF) $(INSTALL_ETC)
39
 		rm -f $(MAN1).gz $(MAN5).gz
40
 #
41
 distfile:
34
 distfile:
35
 		@mkdir -p $(DISTNAME)
36
 		@cp -a $(SRC) $(HDR) $(DISTNAME)
(-)./files/patch-owrep.1 (+13 lines)
Line 0 Link Here
1
--- owrep.1.orig	2018-03-07 09:22:26 UTC
2
+++ owrep.1
3
@@ -105,8 +105,8 @@ provided.
4
 .It 34 Ta time Ta Time of last update
5
 .El
6
 .Sh FILES
7
-.Bl -tag -width /usr/local/etc/owrep.conf -compact
8
-.It Pa /usr/local/etc/owrep.conf
9
+.Bl -tag -width %%PREFIX%%/etc/owrep.conf -compact
10
+.It Pa %%PREFIX%%/etc/owrep.conf
11
 default configuration file
12
 .El
13
 .Sh EXIT STATUS
(-)./files/patch-owrep.c (+11 lines)
Line 0 Link Here
1
--- owrep.c.orig	2018-03-04 22:10:17 UTC
2
+++ owrep.c
3
@@ -20,7 +20,7 @@
4
 
5
 #include "owrep.h"
6
 
7
-#define	DEFAULT_CONFIG	"/usr/local/etc/owrep.conf"
8
+#define	DEFAULT_CONFIG	"%%PREFIX%%/etc/owrep.conf"
9
 
10
 /* Forward references */
11
 
(-)./pkg-descr (-1 / +1 lines)
Lines 1-4 Link Here
1
This is a basic weather reporting program. It uses data from
1
This is a basic weather reporting program. It uses data from
2
openweathermap.org, and uses a worldwide database.
2
openweathermap.org, and uses a worldwide database.
3
3
4
WWW: http://www.tavi.co.uk
4
WWW: http://www.bobeager.uk/software.html
(-)./pkg-plist (-1 / +1 lines)
Lines 1-4 Link Here
1
bin/owrep
1
bin/owrep
2
%%ETCDIR%%.conf.sample
2
@sample etc/owrep.conf.sample
3
man/man1/owrep.1.gz
3
man/man1/owrep.1.gz
4
man/man5/owrep.conf.5.gz
4
man/man5/owrep.conf.5.gz

Return to bug 226535