aboutsummaryrefslogtreecommitdiff
path: root/tools/hex2bin-2.0/Makefile
diff options
context:
space:
mode:
authorJuan J. Martinez <jjm@usebox.net>2021-01-18 19:16:59 +0000
committerJuan J. Martinez <jjm@usebox.net>2021-01-18 19:16:59 +0000
commit71124479ed9f7e88f7b11f3ad4175000e2f21c4e (patch)
tree7fe95b7cd81c96839f97ac514997652c2513f3b5 /tools/hex2bin-2.0/Makefile
parent97ba35b1bc0719dc3b0c981534de196c3d68d1a5 (diff)
downloadubox-msx-lib-71124479ed9f7e88f7b11f3ad4175000e2f21c4e.tar.gz
ubox-msx-lib-71124479ed9f7e88f7b11f3ad4175000e2f21c4e.zip
Better windows support
Diffstat (limited to 'tools/hex2bin-2.0/Makefile')
-rwxr-xr-xtools/hex2bin-2.0/Makefile7
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/hex2bin-2.0/Makefile b/tools/hex2bin-2.0/Makefile
index c8ef10b..0939450 100755
--- a/tools/hex2bin-2.0/Makefile
+++ b/tools/hex2bin-2.0/Makefile
@@ -17,6 +17,12 @@ CPFLAGS = -std=gnu99 -O3 -fsigned-char -Wall -pedantic
# Compile
all: objectdir $(TGT_FILES)
+ifdef ($(OS),Windows_NT)
+ TARGET = hex2bin.exe
+else
+ TARGET = hex2bin
+endif
+
$(OBJDIR)/%.o: $(SRCDIR)/%.c
gcc -c $(CPFLAGS) $< -o $@
@@ -29,6 +35,7 @@ $(TGTDIR)/hex2bin.1: $(SRCDIR)/hex2bin.pod
$(TGTDIR)/hex2bin: $(B_OBJFILES)
gcc $(CPFLAGS) -o $(TGTDIR)/hex2bin $(B_OBJFILES)
+ cp bin/$(TARGET) ../../bin
$(TGTDIR)/mot2bin: $(M_OBJFILES)
gcc $(CPFLAGS) -o $(TGTDIR)/mot2bin $(M_OBJFILES)