1MAGIC = $(pkgdatadir)/magic 2lib_LTLIBRARIES = libmagic.la 3nodist_include_HEADERS = magic.h 4 5bin_PROGRAMS = file 6 7AM_CPPFLAGS = -DMAGIC='"$(MAGIC)"' 8AM_CFLAGS = $(CFLAG_VISIBILITY) @WARNINGS@ 9 10libmagic_la_SOURCES = buffer.c magic.c apprentice.c softmagic.c ascmagic.c \ 11 encoding.c compress.c is_csv.c is_json.c is_tar.c readelf.c print.c \ 12 fsmagic.c funcs.c file.h readelf.h tar.h apptype.c der.c der.h \ 13 file_opts.h elfclass.h mygetopt.h cdf.c cdf_time.c readcdf.c cdf.h 14libmagic_la_LDFLAGS = -no-undefined -version-info 1:0:0 15if MINGW 16MINGWLIBS = -lgnurx -lshlwapi 17else 18MINGWLIBS = 19endif 20libmagic_la_LIBADD = $(LTLIBOBJS) $(MINGWLIBS) 21 22file_SOURCES = file.c seccomp.c 23file_LDADD = libmagic.la 24CLEANFILES = magic.h 25EXTRA_DIST = magic.h.in cdf.mk BNF memtest.c 26HDR= $(top_srcdir)/src/magic.h.in 27BUILT_SOURCES = magic.h 28 29magic.h: ${HDR} 30 sed -e "s/X.YY/$$(echo @VERSION@ | tr -d .)/" < ${HDR} > $@ 31