diff options
author | Přemysl Eric Janouch <p@janouch.name> | 2024-11-25 04:53:27 +0100 |
---|---|---|
committer | Přemysl Eric Janouch <p@janouch.name> | 2024-11-25 05:46:26 +0100 |
commit | 0283189070f577e77d8f6a41c00d7cd69709ce14 (patch) | |
tree | 14834b350167eff75cd714b71d6668a2c056692f /Makefile | |
parent | 3219d87bc4453a2e34d5e017979d2746d13fe1d4 (diff) | |
download | usb-drivers-0283189070f577e77d8f6a41c00d7cd69709ce14.tar.gz usb-drivers-0283189070f577e77d8f6a41c00d7cd69709ce14.tar.xz usb-drivers-0283189070f577e77d8f6a41c00d7cd69709ce14.zip |
Port eizoctl build to CMake
The GNU Makefile approach has its limits.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/Makefile b/Makefile deleted file mode 100644 index 4246b3a..0000000 --- a/Makefile +++ /dev/null @@ -1,38 +0,0 @@ -UNAME_S := $(shell uname -s) -ifeq ($(UNAME_S),Linux) - HIDAPI = hidapi-hidraw -else - HIDAPI = hidapi -endif - -CFLAGS += -Wall -Wextra -g -std=gnu99 $(shell pkg-config --cflags $(HIDAPI)) -LDFLAGS += $(shell pkg-config --libs $(HIDAPI)) -outputs = eizoctl compile_commands.json -ifeq ($(OS),Windows_NT) - outputs += eizoctltray.png eizoctltray.ico eizoctltray.o eizoctltray.exe - LDFLAGS += -static -endif - -all: $(outputs) -compile_commands.json: - >$@ echo '[{' - >>$@ echo '"directory": "'"$$(pwd)"'",' - >>$@ echo '"command": "$(CC) $(CFLAGS) eizoctl.c",' - >>$@ echo '"file": "'"$$(pwd)"'/eizoctl.c"' - >>$@ echo '}]' -eizoctl: eizoctl.c - $(CC) $(CFLAGS) $(CPPFLAGS) -o $@ $^ $(LDFLAGS) -clean: - rm -f $(outputs) - -ifeq ($(OS),Windows_NT) -eizoctltray.png: eizoctltray.svg - rsvg-convert --output=$@ -- $< -eizoctltray.ico: eizoctltray.png - icotool -c -o $@ -- $< -eizoctltray.o: eizoctltray.rc eizoctltray.ico - windres -o $@ $< -eizoctltray.exe: eizoctl.c eizoctltray.o - $(CC) $(CFLAGS) $(CPPFLAGS) -DUNICODE -D_UNICODE -DTRAY \ - -o $@ $^ $(LDFLAGS) -mwindows -municode -lPowrProf -endif |