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 = magic.c apprentice.c softmagic.c ascmagic.c \ 11 encoding.c compress.c is_tar.c readelf.c print.c fsmagic.c \ 12 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 23file_LDADD = libmagic.la 24CLEANFILES = magic.h 25EXTRA_DIST = magic.h.in 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