diff options
author | Thierry Thomas <thierry@FreeBSD.org> | 2006-01-30 23:25:17 +0000 |
---|---|---|
committer | Thierry Thomas <thierry@FreeBSD.org> | 2006-01-30 23:25:17 +0000 |
commit | d503a25a2c83f4dd12970141d8b2157aab37beb5 (patch) | |
tree | 111614c6a5e0915f05f9c29a66f1eee068c9aeb1 /converters | |
parent | a06ee65df0af4a27507365d7991910fcc6881d95 (diff) | |
download | ports-d503a25a2c83f4dd12970141d8b2157aab37beb5.tar.gz ports-d503a25a2c83f4dd12970141d8b2157aab37beb5.zip |
Notes
Diffstat (limited to 'converters')
-rw-r--r-- | converters/Makefile | 1 | ||||
-rw-r--r-- | converters/ascii2binary/Makefile | 48 | ||||
-rw-r--r-- | converters/ascii2binary/distinfo | 3 | ||||
-rw-r--r-- | converters/ascii2binary/files/patch-Makefile | 49 | ||||
-rw-r--r-- | converters/ascii2binary/pkg-descr | 20 |
5 files changed, 121 insertions, 0 deletions
diff --git a/converters/Makefile b/converters/Makefile index 5b99a975fa4d..b860c7bcc3b1 100644 --- a/converters/Makefile +++ b/converters/Makefile @@ -4,6 +4,7 @@ COMMENT = Character code converters SUBDIR += aish + SUBDIR += ascii2binary SUBDIR += asr10 SUBDIR += base64 SUBDIR += btoa diff --git a/converters/ascii2binary/Makefile b/converters/ascii2binary/Makefile new file mode 100644 index 000000000000..66ff43f3a6a9 --- /dev/null +++ b/converters/ascii2binary/Makefile @@ -0,0 +1,48 @@ +# New ports collection makefile for: ascii2binary +# Date created: Sun 29 January 2006 +# Whom: thierry@pompo.net +# +# $FreeBSD$ +# + +PORTNAME= ascii2binary +PORTVERSION= 2.8.1 +CATEGORIES= converters +MASTER_SITES= http://billposer.org/Software/Downloads/ +DISTNAME= ${PORTNAME} +EXTRACT_SUFX= .tgz +DIST_SUBDIR= ${PORTNAME}-${PORTVERSION} + +MAINTAINER= thierry@FreeBSD.org +COMMENT= Convert between textual representations of numbers and binary + +HAS_CONFIGURE= yes +CONFIGURE_ENV= CPPFLAGS="${CFLAGS} -I${LOCALBASE}/include" \ + LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib" \ + LIBS="-lintl" +MAKE_ENV= CPPFLAGS="${CFLAGS} -I${LOCALBASE}/include" \ + LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib" \ + LIBS="-lintl" +USE_GETTEXT= yes +WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:R} + +PLIST_FILES= bin/ascii2binary bin/binary2ascii \ + %%NLS%%share/locale/fr/LC_MESSAGES/ascii2binary.mo + +MAN1= ascii2binary.1 binary2ascii.1 + +.if defined(WITHOUT_NLS) +PLIST_SUB= NLS="@comment " +.else +PLIST_SUB= NLS="" +.endif + +pre-configure: +.if defined(WITHOUT_NLS) + ${REINPLACE_CMD} -e 's|cp -r locale|#cp -r locale|' ${WRKSRC}/Makefile +.endif + +post-install: + @${FIND} ${PREFIX}/share/locale -name ascii2binary.po -delete + +.include <bsd.port.mk> diff --git a/converters/ascii2binary/distinfo b/converters/ascii2binary/distinfo new file mode 100644 index 000000000000..3e06686236b4 --- /dev/null +++ b/converters/ascii2binary/distinfo @@ -0,0 +1,3 @@ +MD5 (ascii2binary-2.8.1/ascii2binary.tgz) = f15f907641203950213f48a43e2d4f45 +SHA256 (ascii2binary-2.8.1/ascii2binary.tgz) = e50c61237fb0c42859d40155ac37c4a93eb6ca053c0c6df6c74d24704af98a59 +SIZE (ascii2binary-2.8.1/ascii2binary.tgz) = 61894 diff --git a/converters/ascii2binary/files/patch-Makefile b/converters/ascii2binary/files/patch-Makefile new file mode 100644 index 000000000000..ef22206e6959 --- /dev/null +++ b/converters/ascii2binary/files/patch-Makefile @@ -0,0 +1,49 @@ +--- Makefile.orig Mon Sep 12 19:35:10 2005 ++++ Makefile Mon Jan 30 00:09:11 2006 +@@ -1,28 +1,27 @@ +-CC=gcc +-BINDIR=/usr/local/bin +-MANDIR=/usr/local/man/man1 ++BINDIR=${PREFIX}/bin ++MANDIR=${PREFIX}/man/man1 + BINS= ascii2binary binary2ascii + MANS= ascii2binary.1 binary2ascii.1 +-LOCALEDIR=/usr/local/share/locale +-CFLAGS= -DPACKAGE=\"ascii2binary\" -DLOCALEDIR=\"${LOCALEDIR}\" ++LOCALEDIR=${PREFIX}/share/locale ++CFLAGS= ${CPPFLAGS} -DPACKAGE=\"ascii2binary\" -DLOCALEDIR=\"${LOCALEDIR}\" + all: ${BINS} mo + #CFLAGS= -DPACKAGE=\"ascii2binary\" -DLOCALEDIR=\"${LOCALEDIR}\" + #all: ${BINS} + + ascii2binary: ascii2binary.o GetWord.o MachineInfo.o endian.o exitcodes.o +- ${CC} -o ascii2binary ascii2binary.o GetWord.o MachineInfo.o endian.o exitcodes.o ++ ${CC} ${LDFLAGS} -o ascii2binary ascii2binary.o GetWord.o MachineInfo.o endian.o exitcodes.o ${LIBS} + + binary2ascii: binary2ascii.o binfmt.o MachineInfo.o endian.o exitcodes.o +- ${CC} -o binary2ascii binary2ascii.o binfmt.o MachineInfo.o endian.o exitcodes.o ++ ${CC} ${LDFLAGS} -o binary2ascii binary2ascii.o binfmt.o MachineInfo.o endian.o exitcodes.o ${LIBS} + + MachineInfo.o: MachineInfo.c +- ${CC} -c MachineInfo.c ++ ${CC} -c ${CFLAGS} MachineInfo.c + + GetWord.o: GetWord.c +- ${CC} -c GetWord.c ++ ${CC} -c ${CFLAGS} GetWord.c + + binfmt.o: binfmt.c +- ${CC} -c binfmt.c ++ ${CC} -c ${CFLAGS} binfmt.c + + exitcodes.o: exitcodes.c + ${CC} -c ${CFLAGS} exitcodes.c +@@ -33,7 +32,7 @@ + binary2ascii.o: binary2ascii.c + ${CC} ${CFLAGS} -c binary2ascii.c + +-mo: ++mo: + (cd locale/fr/LC_MESSAGES; make ascii2binary.mo) + + install: ${BINS} ${MANS} diff --git a/converters/ascii2binary/pkg-descr b/converters/ascii2binary/pkg-descr new file mode 100644 index 000000000000..94fd043bc239 --- /dev/null +++ b/converters/ascii2binary/pkg-descr @@ -0,0 +1,20 @@ +These programs convert between textual and binary representations of numbers. +ascii2binary reads input consisting of textual representations of numbers +separated by whitespace and produces as output the binary equivalents. The type +and precision of the binary output is selected using command line flags. + +binary2ascii reads input consisting of binary numbers and converts them to +their textual representation. Command line flags specify the type and size +of the binary numbers and provide control over the format of the output. +Unsigned integers may be written out in binary, octal, decimal, or hexadecimal. +Signed integers may be written out only in binary or decimal. Floating point +numbers may be written out only decimal, either in standard or scientific +notation. (If you want to examine the binary representation of floating point +numbers, just treat the input as a sequence of unsigned characters.) + +The two programs are useful for generating test data, for inspecting binary +files, and for interfacing programs that generate textual output to programs +that require binary input and conversely. They can also be useful when it is +desired to reformat numbers. + +WWW: http://billposer.org/Software/a2b.html |