File tree Expand file tree Collapse file tree 1 file changed +10
-6
lines changed
Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change 11
2- CC ?= gcc
2+ CC ?= gcc
3+ CXX ?= g++
4+
5+ CFLAGS += $(shell pkg-config --cflags jack)
6+ LDFLAGS += $(shell pkg-config --libs jack)
37
48TESTS =test_new test_cond_wait test_cond_wait_simple test_printf
59
610all : jack_interposer.so
711
812jack_interposer.so : jack_interposer.c checkers.c manual.c
9- $(CC ) $< $ (CFLAGS ) -Wall -fPIC $(LDFLAGS ) -Wl,--no-undefined -shared -pthread -ldl -ljack -o jack_interposer.so
13+ $(CC ) $< -o $@ $ (CFLAGS ) -Wall -fPIC $(LDFLAGS ) -Wl,--no-undefined -shared -pthread -ldl
1014
1115checkers.c : functions checker_fragment.c
1216 ./generate_checkers.pl < functions
@@ -21,13 +25,13 @@ test: $(TESTS) jack_interposer.so
2125 LD_PRELOAD=./jack_interposer.so ./test_printf
2226
2327test_new : test_new.cpp
24- g++ -o test_new test_new.cpp -ljack
28+ $( CXX ) $< -o $@ $( CFLAGS ) $( LDFLAGS )
2529
2630test_cond_wait_simple : test_cond_wait_simple.c
27- gcc -o test_cond_wait_simple test_cond_wait_simple.c -pthread -ldl
31+ $( CC ) $< -o $@ $( CFLAGS ) $( LDFLAGS ) -pthread -ldl
2832
2933test_cond_wait : test_cond_wait.c
30- gcc -o test_cond_wait test_cond_wait.c -ljack -lpthread
34+ $( CC ) $< -o $@ $( CFLAGS ) $( LDFLAGS ) -pthread
3135
3236test_printf : test_printf.c
33- gcc -o test_printf test_printf.c -ljack
37+ $( CC ) $< -o $@ $( CFLAGS ) $( LDFLAGS )
You can’t perform that action at this time.
0 commit comments