diff options
author | ehaupt <ehaupt@FreeBSD.org> | 2006-12-26 00:02:15 +0800 |
---|---|---|
committer | ehaupt <ehaupt@FreeBSD.org> | 2006-12-26 00:02:15 +0800 |
commit | bc82105755a1e733cbfc18c462923d22630cd53f (patch) | |
tree | 725ee82113d894156e437373d413012d441e089d /sysutils | |
parent | 974e95d1e884dc1cd5e78c419bdcd51614eda13c (diff) | |
download | freebsd-ports-gnome-bc82105755a1e733cbfc18c462923d22630cd53f.tar.gz freebsd-ports-gnome-bc82105755a1e733cbfc18c462923d22630cd53f.tar.zst freebsd-ports-gnome-bc82105755a1e733cbfc18c462923d22630cd53f.zip |
Add linrename 2.12r, rename multiple files using substitution.
PR: 106658
Submitted by: Jonathan Liu <Net147 at hotmail.com>
Diffstat (limited to 'sysutils')
-rw-r--r-- | sysutils/Makefile | 1 | ||||
-rw-r--r-- | sysutils/linrename/Makefile | 39 | ||||
-rw-r--r-- | sysutils/linrename/distinfo | 3 | ||||
-rw-r--r-- | sysutils/linrename/files/patch-lib__nls.h | 42 | ||||
-rw-r--r-- | sysutils/linrename/files/patch-misc-utils__rename.1 | 37 | ||||
-rw-r--r-- | sysutils/linrename/files/patch-misc-utils__rename.c | 11 | ||||
-rw-r--r-- | sysutils/linrename/pkg-descr | 4 |
7 files changed, 137 insertions, 0 deletions
diff --git a/sysutils/Makefile b/sysutils/Makefile index 51d7ce24187d..d9eee0795a4c 100644 --- a/sysutils/Makefile +++ b/sysutils/Makefile @@ -334,6 +334,7 @@ SUBDIR += lineak-kdeplugins SUBDIR += lineak-xosdplugin SUBDIR += lineakd + SUBDIR += linrename SUBDIR += linux-acu SUBDIR += linux-afaapps SUBDIR += linux-megacli diff --git a/sysutils/linrename/Makefile b/sysutils/linrename/Makefile new file mode 100644 index 000000000000..12f155f8bb6c --- /dev/null +++ b/sysutils/linrename/Makefile @@ -0,0 +1,39 @@ +# Ports collection makefile for: linrename +# Date created: December 13 2006 +# Whom: Jonathan Liu <Net147@hotmail.com> +# +# $FreeBSD$ +# + +PORTNAME= linrename +PORTVERSION= 2.12r +CATEGORIES= sysutils +MASTER_SITES= http://www.kernel.org/pub/linux/utils/util-linux/ +DISTNAME= util-linux-${PORTVERSION} + +MAINTAINER= Net147@hotmail.com +COMMENT= Rename multiple files using substitution + +PLIST_FILES= bin/linrename +MAN1= linrename.1 + +USE_BZIP2= yes +USE_GETTEXT= yes +USE_GCC= 3.4+ + +CFLAGS+= -I${LOCALBASE}/include -L${LOCALBASE}/lib -lintl -I${WRKSRC}/lib +EXTRACT_AFTER_ARGS= | tar -xf - \ + ${DISTNAME}/lib/nls.h \ + ${DISTNAME}/misc-utils/rename.1 \ + ${DISTNAME}/misc-utils/rename.c + +.include <bsd.port.pre.mk> + +do-build: + ${CC} ${CFLAGS} -o ${WRKSRC}/${PORTNAME} ${WRKSRC}/misc-utils/rename.c + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin + ${INSTALL_MAN} ${WRKSRC}/misc-utils/rename.1 ${PREFIX}/man/man1/${MAN1} + +.include <bsd.port.post.mk> diff --git a/sysutils/linrename/distinfo b/sysutils/linrename/distinfo new file mode 100644 index 000000000000..bf7f8f7e2068 --- /dev/null +++ b/sysutils/linrename/distinfo @@ -0,0 +1,3 @@ +MD5 (util-linux-2.12r.tar.bz2) = af9d9e03038481fbf79ea3ac33f116f9 +SHA256 (util-linux-2.12r.tar.bz2) = b8e499b338ce9fbd1fb315194b26540ec823c0afc46c9e145ac7a3e38ad57e6b +SIZE (util-linux-2.12r.tar.bz2) = 1370907 diff --git a/sysutils/linrename/files/patch-lib__nls.h b/sysutils/linrename/files/patch-lib__nls.h new file mode 100644 index 000000000000..e8ef01d418ce --- /dev/null +++ b/sysutils/linrename/files/patch-lib__nls.h @@ -0,0 +1,42 @@ +--- ./lib/nls.h.orig Thu Jul 4 23:03:26 2002 ++++ ./lib/nls.h Mon Dec 25 14:54:11 2006 +@@ -1,7 +1,5 @@ + int main(int argc, char *argv[]); + +-#include "../defines.h" /* for HAVE_locale_h */ +- + #ifndef PACKAGE + #define PACKAGE "util-linux" + #endif +@@ -10,25 +8,12 @@ + #define LOCALEDIR "/usr/share/locale" + #endif + +-#ifdef HAVE_locale_h +-# include <locale.h> +-#endif ++#include <locale.h> + +-#if defined MAY_ENABLE_NLS && !defined DISABLE_NLS +-# include <libintl.h> +-# define _(Text) gettext (Text) +-# ifdef gettext_noop +-# define N_(String) gettext_noop (String) +-# else +-# define N_(String) (String) +-# endif ++#include <libintl.h> ++#define _(Text) gettext (Text) ++#ifdef gettext_noop ++# define N_(String) gettext_noop (String) + #else +-# undef bindtextdomain +-# define bindtextdomain(Domain, Directory) /* empty */ +-# undef textdomain +-# define textdomain(Domain) /* empty */ +-# define _(Text) (Text) +-# define N_(Text) (Text) ++# define N_(String) (String) + #endif +- +- diff --git a/sysutils/linrename/files/patch-misc-utils__rename.1 b/sysutils/linrename/files/patch-misc-utils__rename.1 new file mode 100644 index 000000000000..58de31e772ea --- /dev/null +++ b/sysutils/linrename/files/patch-misc-utils__rename.1 @@ -0,0 +1,37 @@ +--- ./misc-utils/rename.1.orig Sun Aug 22 17:14:45 2004 ++++ ./misc-utils/rename.1 Mon Dec 25 14:54:11 2006 +@@ -3,11 +3,11 @@ + .\" + .TH RENAME 1 "1 January 2000" "" "Linux Programmer's Manual" + .SH NAME +-rename \- Rename files ++linrename \- Rename files + .SH SYNOPSIS +-.BI rename " from to file..." ++.BI linrename " from to file..." + .SH DESCRIPTION +-.B rename ++.B linrename + will rename the specified files by replacing the first occurrence of + .I from + in their name by +@@ -19,8 +19,8 @@ + + .RS + .nf +-rename foo foo0 foo? +-rename foo foo0 foo?? ++linrename foo foo0 foo? ++linrename foo foo0 foo?? + .fi + .RE + +@@ -30,7 +30,7 @@ + And + .RS + .nf +-rename .htm .html *.htm ++linrename .htm .html *.htm + .fi + .RE + diff --git a/sysutils/linrename/files/patch-misc-utils__rename.c b/sysutils/linrename/files/patch-misc-utils__rename.c new file mode 100644 index 000000000000..de69e27ecd23 --- /dev/null +++ b/sysutils/linrename/files/patch-misc-utils__rename.c @@ -0,0 +1,11 @@ +--- ./misc-utils/rename.c.orig Tue May 9 23:39:03 2000 ++++ ./misc-utils/rename.c Mon Dec 25 14:54:11 2006 +@@ -19,6 +19,8 @@ + #include <errno.h> + #include "nls.h" + ++#define util_linux_version "util-linux-2.12r" ++ + static char *progname; + + static int diff --git a/sysutils/linrename/pkg-descr b/sysutils/linrename/pkg-descr new file mode 100644 index 000000000000..3bf47997737a --- /dev/null +++ b/sysutils/linrename/pkg-descr @@ -0,0 +1,4 @@ +Rename is a port of the Linux rename utility included with util-linux. +It allows renaming multiple files using substitution. + +WWW: http://freshmeat.net/projects/util-linux/ |