AppImageKit-checkrt/Makefile
darealshinji caf91e2408
C99
2017-12-06 21:44:09 +01:00

26 lines
518 B
Makefile

CFLAGS ?= -O2 -Wall -Wextra
LDFLAGS += -s
BIN = AppRun_patched
LIB = exec.so
all: $(BIN) $(LIB)
clean:
-rm -f $(BIN) $(LIB) *.o AppRun.c AppRun_patched.c
$(BIN): AppRun_patched.o checkrt.o
$(LIB): exec.o
$(CC) -shared $(LDFLAGS) -o $@ $^ -ldl
AppRun_patched.o checkrt.o: CFLAGS += -include checkrt.h
exec.o: CFLAGS += -fPIC -std=c99
AppRun_patched.c: AppRun.c
patch -p1 --output $@ < AppRun.c.patch
AppRun.c:
wget -c "https://raw.githubusercontent.com/probonopd/AppImageKit/appimagetool/master/AppRun.c"