mirror of
git://sigrok.org/libserialport
synced 2023-08-10 21:13:24 +03:00
Add examples directory with two example programs.
This commit is contained in:
16
examples/Makefile
Normal file
16
examples/Makefile
Normal file
@@ -0,0 +1,16 @@
|
||||
CC = gcc
|
||||
PKG_CONFIG = pkg-config
|
||||
CFLAGS = -g -Wall $(shell $(PKG_CONFIG) --cflags libserialport)
|
||||
LIBS = $(shell $(PKG_CONFIG) --libs libserialport)
|
||||
|
||||
SOURCES = $(wildcard *.c)
|
||||
|
||||
BINARIES = $(SOURCES:.c=)
|
||||
|
||||
%: %.c
|
||||
$(CC) $(CFLAGS) $< $(LIBS) -o $@
|
||||
|
||||
all: $(BINARIES)
|
||||
|
||||
clean:
|
||||
rm $(BINARIES)
|
||||
Reference in New Issue
Block a user