diff options
author | B. Watson <urchlay@slackware.uk> | 2022-11-11 19:37:05 -0500 |
---|---|---|
committer | B. Watson <urchlay@slackware.uk> | 2022-11-11 19:37:05 -0500 |
commit | c137b0274dba5f91a03fab94d60d252338e0fd47 (patch) | |
tree | 153b2c47a20d14fd310550b662b626f7c18ed951 | |
parent | 18da4023b7fb86f96023ed492e11268609ea62d4 (diff) | |
download | dla-asm-c137b0274dba5f91a03fab94d60d252338e0fd47.tar.gz |
Embed version number in dla2img.sh.
-rw-r--r-- | Makefile | 5 | ||||
-rw-r--r-- | d2iver.pl | 4 | ||||
-rwxr-xr-x | dla2img.sh | 5 |
3 files changed, 12 insertions, 2 deletions
@@ -9,13 +9,16 @@ PERL=perl CC=cc CFLAGS=-O2 -Wall -all: dla.xex dla2csv dla2csv.xex +all: dla.xex dla2csv dla2csv.xex dla2img.sh dla.xex: dla.s io.s dlatbl.s xex.inc printint.s render.s drunkwalk.s dlaver.h $(CL65) $(CL65FLAGS) -l dla.list -Ln dla.labels -t none -o dla.xex dla.s dla2csv.xex: dla2csv.c dlaver.h +dla2img.sh: VERSION + $(PERL) d2iver.pl dla2img.sh + dlatbl.s: mkdlatbl.pl $(PERL) mkdlatbl.pl > dlatbl.s diff --git a/d2iver.pl b/d2iver.pl new file mode 100644 index 0000000..b6cc951 --- /dev/null +++ b/d2iver.pl @@ -0,0 +1,4 @@ +#!/usr/bin/perl -w -i -p + +BEGIN { chomp($v=`cat VERSION`) } +/^VERSION=/ && s,=.*,=$v,; @@ -15,6 +15,9 @@ SELF="`basename $0`" +# This line may get changed by the Makefile (do not hand-edit): +VERSION=0.2.1 + # allow overriding magick path via environment. if [ "$MAGICK" = "" ]; then MAGICK="magick" @@ -31,7 +34,7 @@ OUTFILE="$2" if [ -z "$INFILE" -o -z "$OUTFILE" -o "$INFILE" = "-h" -o "$INFILE" = "--help" ]; then cat <<EOF -$SELF - convert saved files from dla.xex to image files. +$SELF v$VERSION - convert dla.xex saved files to image files. Usage: $SELF [dla-file] [image-file] <magick-arguments ...> |