system/nrg2cue: Added (convert .nrg CD images)

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
B. Watson 2022-01-11 12:25:05 -05:00 committed by Willy Sudiarto Raharjo
parent b997592d92
commit 7eed4f4162
No known key found for this signature in database
GPG key ID: 3F617144D7238786
4 changed files with 114 additions and 0 deletions

9
system/nrg2cue/README Normal file
View file

@ -0,0 +1,9 @@
nrg2cue (convert Nero .nrg CD images to bin/cue)
Usage: nrg2cue <file.NRG> [output.ISO]
If you specify the output ISO file, it will be generated too.
If you're wondering "Where is the .bin file?", the answer is that the
generated .cue file uses the .nrg image as the "bin" file, since it
contains all the data in the image anyway.

View file

@ -0,0 +1,76 @@
#!/bin/bash
# Slackware build script for nrg2cue
# Written by B. Watson (yalhcru@gmail.com)
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=nrg2cue
VERSION=${VERSION:-0.1.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
fi
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
fi
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
fi
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
mkdir -p $PRGNAM-$VERSION
cd $PRGNAM-$VERSION
unzip -p $CWD/$PRGNAM.zip $PRGNAM.c > $PRGNAM.c
PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
# This is just a single C source file, with no documentation or even a
# Makefile.
mkdir -p $PKG/usr/bin $PKGDOC
${CC:-gcc} $SLKCFLAGS -Wl,-s -o $PKG/usr/bin/$PRGNAM $PRGNAM.c
# The license is GPL, in comments in the source.
sed -n '2,18p' $PRGNAM.c > $PKGDOC/LICENSE
# Include our own README, it may be helpful.
cat $CWD/README > $PKGDOC/README
cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}

View file

@ -0,0 +1,10 @@
PRGNAM="nrg2cue"
VERSION="0.1.1"
HOMEPAGE="https://aluigi.altervista.org/mytoolz.htm"
DOWNLOAD="https://aluigi.altervista.org/mytoolz/nrg2cue.zip"
MD5SUM="eb4d8416d18f9ee59f9f3f21016b6820"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""
MAINTAINER="B. Watson"
EMAIL="yalhcru@gmail.com"

19
system/nrg2cue/slack-desc Normal file
View file

@ -0,0 +1,19 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description.
# Line up the first '|' above the ':' following the base package name, and
# the '|' on the right side marks the last column you can put a character in.
# You must make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
nrg2cue: nrg2cue (convert Nero .nrg CD images to bin/cue)
nrg2cue:
nrg2cue: Usage: nrg2cue <file.NRG> [output.ISO]
nrg2cue:
nrg2cue: If you specify the output ISO file, it will be generated too.
nrg2cue:
nrg2cue:
nrg2cue:
nrg2cue:
nrg2cue:
nrg2cue: