AM_CPPFLAGS += -I$(srcdir) -g
+# Disable some warnings flags to accomodate the tracepoint headers
+AM_CFLAGS += \
+ -Wno-redundant-decls
+
noinst_PROGRAMS = prog
prog_SOURCES = prog.c tp.c tp.h
prog_LDADD = $(UST_LIBS) $(DL_LIBS)
# Extract debug symbols
prog.debug: prog
- $(objcopy_verbose)$(OBJCOPY) --only-keep-debug prog prog.debug
+ $(objcopy_verbose)$(LIBTOOL) --mode=execute $(OBJCOPY) --only-keep-debug prog prog.debug
# Strip and add debuglink
prog.strip: prog.debug
- @cp -f prog prog.strip
+ @$(LIBTOOL) --mode=execute cp -f prog prog.strip
$(objcopy_verbose)$(OBJCOPY) --strip-debug --add-gnu-debuglink=prog.debug prog.strip
all-local: prog.strip