projects
/
fw
/
stlink
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Align loader to 32-bit boundary
[fw/stlink]
/
gdbserver
/
Makefile
diff --git
a/gdbserver/Makefile
b/gdbserver/Makefile
index 85b0ac1d67b6f87d77bb54b4485558dc1398ab8d..bd5c73dbc9107f0be46c32533a604001d4d29362 100644
(file)
--- a/
gdbserver/Makefile
+++ b/
gdbserver/Makefile
@@
-1,28
+1,16
@@
-# make ... for both libusb and libsg
-#
-# make CONFIG_USE_LIBSG=0 ...
-# for just libusb
-#
-
PRG := st-util
OBJS = gdb-remote.o gdb-server.o
CFLAGS+=-g -Wall -Werror -std=gnu99 -I../src
PRG := st-util
OBJS = gdb-remote.o gdb-server.o
CFLAGS+=-g -Wall -Werror -std=gnu99 -I../src
-CFLAGS+=-DCONFIG_USE_LIBUSB=1
-CFLAGS+=-DCONFIG_USE_LIBSG=$(CONFIG_USE_LIBSG)
-LDFLAGS=-L.. -lstlink -lusb-1.0
-
-ifeq ($(CONFIG_USE_LIBSG),)
-CONFIG_USE_LIBSG=1
-endif
+LDFLAGS=-L.. -lstlink
-ifneq ($(CONFIG_USE_LIBSG),0)
-LDFLAGS+=
-lsgutils2
-endif
+# libusb location
+LDFLAGS+=
`pkg-config --libs libusb-1.0`
+CFLAGS+=`pkg-config --cflags libusb-1.0`
all: $(PRG)
all: $(PRG)
-$(PRG): $(OBJS)
+$(PRG): $(OBJS)
../libstlink.a
$(CC) -o $@ $^ $(LDFLAGS)
clean:
$(CC) -o $@ $^ $(LDFLAGS)
clean: