X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=support%2Fmakebin%2FMakefile;h=66e49b30858715328d7494214e6b6a4cb4e5bde7;hb=72b7e8dadd92279596c0f56649775fc056acf449;hp=481910c79302350c4b2464afbe5246047a8810c2;hpb=da5ade526c6f614e337918af7d56e9fcd9ccb180;p=fw%2Fsdcc diff --git a/support/makebin/Makefile b/support/makebin/Makefile index 481910c7..66e49b30 100644 --- a/support/makebin/Makefile +++ b/support/makebin/Makefile @@ -1,10 +1,21 @@ -BIN = makebin -OBJ = makebin.o +PRJDIR = ../.. + +SOURCES = makebin.c +BIN = $(PRJDIR)/bin/makebin$(EXEEXT) + +include $(PRJDIR)/Makefile.common all: $(BIN) -clean: - rm -f $(BIN) $(OBJ) *~ +$(BIN): $(OBJ) + $(CC) $(LDFLAGS) -o $(BIN) $(OBJ) install: all - install --strip $(BIN) /usr/bin \ No newline at end of file + mkdir -p $(bindir) + $(INSTALL) $(BIN) `echo $(bindir)/makebin$(EXEEXT)|sed '$(transform)'` + $(STRIP) `echo $(bindir)/makebin$(EXEEXT)|sed '$(transform)'` + +uninstall: + rm -f $(bindir)/makebin$(EXEEXT) + +include clean.mk