Revert "Revert "Fix (another) linker library order""
[lttng-ust.git] / doc / examples / hello-static-lib / Makefile
index 81789e2b5b64faacf355ec868bc9dd31f985dc9e..dd246f70a5c274dd465f18cf025e57b5bc678e17 100644 (file)
@@ -37,16 +37,16 @@ endif
 all: hello
 
 lttng-ust-provider-hello.o: tp.c ust_tests_hello.h
-       $(CC) $(CFLAGS) -c -o $@ $<
+       $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 lttng-ust-provider-hello.a: lttng-ust-provider-hello.o
-       ar -rc $@ $<
+       ar -rc $@ $^
 
 hello.o: hello.c
-       $(CC) $(CFLAGS) -c -o $@ $<
+       $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 hello: hello.o lttng-ust-provider-hello.a
-       $(CC) -o $@ $(LDFLAGS) $(LIBS) $^
+       $(CC) -o $@ $(LDFLAGS) $^ $(LIBS)
 
 .PHONY: clean
 clean:
This page took 0.025307 seconds and 4 git commands to generate.