Initial .recipe to build a working dos2unix and unix2dos

This commit is contained in:
Scott McCreary
2013-09-19 15:52:01 -07:00
parent b9cce3c7bc
commit ef9920939f

View File

@@ -1,20 +1,39 @@
DESCRIPTION="dos2unix and unix2dos end of line file converters."
SUMMARY="dos2unix and unix2dos end of line file convertors."
DESCRIPTION="DOS/Windows like to put CR/LF at the end of lines whereas UNIX like to have just LF. Dos2unix and unix2dos are simple parser/converter command line programs to convert between the two formats."
HOMEPAGE="http://www.programmersheaven.com/download/3118/download.aspx"
SRC_URI="svn+http://ports.haiku-files.org/svn/haikuports/trunk/app-text/dos2unix"
SRC_URI="http://ports-space.haiku-files.org/source/dos2unix-1.0.zip"
CHECKSUM_MD5="76c4991341219d71072474255714b010"
REVISION="1"
STATUS_HAIKU="stable"
DEPEND=""
COPYRIGHT="Public Domain"
LICENSE="Public Domain"
ARCHITECTURES="x86 x86_gcc2 x86_64"
PROVIDES="
dos2unix = 1.0 compat >= 1
cmd:dos2unix
cmd:unix2dos
"
REQUIRES="
lib:libroot >= $haikuVersion
"
BUILD_PREREQUIRES="
cmd:gcc
"
SOURCE_DIR="$portVersionedName"
BUILD()
{
cd dos2unix-1.0
gcc -O -o dos2unix DOS2UNIX.C
gcc -O -o unix2dos UNIX2DOS.C
}
INSTALL()
{
cd dos2unix-1.0
mkdir -p ${DESTDIR}`finddir B_COMMON_BIN_DIRECTORY`
cp dos2unix ${DESTDIR}`finddir B_COMMON_BIN_DIRECTORY`/dos2unix
cp unix2dos ${DESTDIR}`finddir B_COMMON_BIN_DIRECTORY`/unix2dos
mkdir -p $binDir
cp dos2unix $binDir/dos2unix
cp unix2dos $binDir/unix2dos
}