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

(-)sysutils/rename/Makefile (-6 / +22 lines)
Lines 2-18 Link Here
2
# $FreeBSD: head/sysutils/rename/Makefile 402160 2015-11-21 14:00:50Z pi $
2
# $FreeBSD: head/sysutils/rename/Makefile 402160 2015-11-21 14:00:50Z pi $
3
3
4
PORTNAME=	rename
4
PORTNAME=	rename
5
PORTVERSION=	1.3
5
PORTVERSION=	1.99.2
6
PORTREVISION=	1
7
CATEGORIES=	sysutils
6
CATEGORIES=	sysutils
8
MASTER_SITES=	http://rename.sourceforge.net/
7
MASTER_SITES=	SF/${PORTNAME}
9
8
10
MAINTAINER=	ports@FreeBSD.org
9
MAINTAINER=	ports@FreeBSD.org
11
COMMENT=	Rename multiple files using regular expressions
10
COMMENT=	Rename multiple files using regular expressions
12
11
13
GNU_CONFIGURE=	yes
12
LICENSE=	GPLv3+
14
USES=		gmake
13
LICENSE_FILE=	${WRKSRC}/COPYING
15
14
16
PLIST_FILES=	bin/${PORTNAME} man/man1/${PORTNAME}.1.gz
15
PLIST_FILES=	bin/renamex man/man1/renamex.1.gz
16
17
post-patch:
18
	@${REINPLACE_CMD} -e \
19
		'/^CC/s|\([[:blank:]]\)\(=\)|\1?\2| ; \
20
		 /^PREFIX/s|\([[:blank:]]\)\(=\)|\1?\2| ; \
21
		 s|/usr/local/bin|$$(PREFIX)/bin| ; \
22
		 s|/usr/local/man|$$(PREFIX)/man| ; \
23
		 /^CFLAGS/s|\([[:blank:]]\)\(=\)|\1+\2| ; \
24
		 s|-O[0-9]|| ; \
25
		 s|$$^$$|$$(OBJS)| ; \
26
		 /cp/s|^|#| ; \
27
		 s|install .* 0755 -s|$${BSD_INSTALL_PROGRAM}| ; \
28
		 s|\([[:blank:]]\)\($$(BINDIR)\)|\1$$(DESTDIR)\2| ; \
29
		 s|install .* 0644|$${BSD_INSTALL_MAN}| ; \
30
		 s|\([[:blank:]]\)\($$(MANDIR)\)|\1$$(DESTDIR)\2| ; \
31
		 s|^%.*|.c.o:|' \
32
		${WRKSRC}/Makefile
17
33
18
.include <bsd.port.mk>
34
.include <bsd.port.mk>
(-)sysutils/rename/distinfo (-2 / +2 lines)
Lines 1-2 Link Here
1
SHA256 (rename-1.3.tar.gz) = 02aed28f46b22213490a94b8490ee2a84b12c0962db33b4ea88c8c67a7adb8f4
1
SHA256 (rename-1.99.2.tar.gz) = c93b4d5c7a7c69bcc06fc25d03a41647b341d07b9425dd530604b665f9d19e22
2
SIZE (rename-1.3.tar.gz) = 83854
2
SIZE (rename-1.99.2.tar.gz) = 77519
(-)sysutils/rename/files/patch-Makefile.in (-37 lines)
Lines 1-37 Link Here
1
--- Makefile.in.orig	2002-05-19 03:28:34 UTC
2
+++ Makefile.in
3
@@ -8,7 +8,7 @@ BINDIR = @prefix@/bin
4
 MANDIR = @prefix@/man/man1
5
 
6
 DEFINES = -DHAVE_CONFIG_H ${VERSION}
7
-CFLAGS = -Wall -O3 ${DEBUG} ${DEFINES}
8
+CFLAGS += -Wall ${DEBUG} ${DEFINES}
9
 
10
 
11
 OBJS = rename.o fixtoken.o misc.o @LIBOBJS@
12
@@ -16,7 +16,7 @@ OBJS = rename.o fixtoken.o misc.o @LIBOB
13
 all: rename
14
 
15
 rename:	$(OBJS)
16
-	$(CC) $(CFLAGS) -o $@ $^
17
+	$(CC) $(CFLAGS) @LDFLAGS@ -o $@ $^
18
 	strip $@
19
 
20
 static:	$(OBJS)
21
@@ -30,11 +30,13 @@ clean-all:
22
 	rm -f core rename *.o config.status config.cache config.h config.log Makefile
23
 
24
 install:
25
-	install -o root -g root -m 0755 -s rename $(BINDIR)
26
-	install -o root -g root -m 0644 rename.1 $(MANDIR)
27
-	
28
+	$(BSD_INSTALL_PROGRAM) rename $(DESTDIR)$(BINDIR)
29
+	$(BSD_INSTALL_MAN) rename.1 $(DESTDIR)$(MANDIR)
30
+
31
 rename.o: rename.c rename.h
32
 regex.o: regex.c regex.h
33
 fixtoken.o: fixtoken.c
34
 misc.o: misc.c
35
 
36
+.c.o:
37
+	$(CC) $(CFLAGS) @CPPFLAGS@ -o $@ -c $<
(-)sysutils/rename/files/patch-rename.c (-28 lines)
Lines 1-28 Link Here
1
--- rename.c.orig	2002-05-20 15:50:50 UTC
2
+++ rename.c
3
@@ -65,7 +65,7 @@
4
 
5
 #if HAVE_REGEX_H
6
   #include <regex.h>
7
-#elif
8
+#else
9
   #include "regex.h"
10
 #endif
11
 
12
@@ -608,7 +608,7 @@ int do_rename(char *oldp, char *newp)
13
 
14
 skip:
15
     if (attr & MOD_VERBO) 
16
-	printf("skiped\n");
17
+	printf("skipped\n");
18
     return rs;
19
 }
20
 
21
@@ -659,6 +659,6 @@ Report bugs to <xuming@bigfoot.com>.\n";
22
     if (mode)  
23
 	printf(version, VERSION);  
24
     else  
25
-	printf(help);
26
+	printf("%s", help);
27
 }
28
 
(-)sysutils/rename/pkg-descr (-4 / +5 lines)
Lines 1-7 Link Here
1
Rename is a quick and powerful tool written in C, featuring extended regular
1
Rename is a quick and powerful tool written in C, featuring extended
2
expression support for searching and substituting pattern strings in filenames.
2
regular expression support for searching and substituting pattern
3
strings in filenames.
3
4
4
Rename can rename, convert to lowercase/uppercase, and change the ownership of
5
Rename can rename, convert to lowercase/uppercase, and change the
5
a large number of files.
6
ownership of a large number of files.
6
7
7
WWW: http://rename.sourceforge.net/
8
WWW: http://rename.sourceforge.net/

Return to bug 208212