1## Process this file with automake to produce Makefile.in 2 3# require automake 1.4 4# gnu strictness chokes on README being autogenerated 5AUTOMAKE_OPTIONS = 1.4 foreign 6 7SUBDIRS = . tests doc 8 9AM_CFLAGS = -g 10 11configincludedir = $(pkglibdir)/include 12 13bin_SCRIPTS = libusb-config 14 15libusb-config: libusb-config.in 16 17EXTRA_DIST = LICENSE libusb.spec.in libusb.spec libusb-config.in README.in README \ 18 INSTALL.libusb.in INSTALL.libusb Doxyfile apidocs/header.html \ 19 apidocs/footer.html apidocs/doxygen.css apidocs/doxygen.png libusb.pc.in 20EXTRA_libusb_la_SOURCE = linux.c linux.h bsd.c darwin.c 21 22lib_LTLIBRARIES = libusb.la libusbpp.la 23 24pkgconfig_DATA = libusb.pc 25 26if LINUX_API 27OS_SUPPORT = linux.c linux.h 28else 29if BSD_API 30OS_SUPPORT = bsd.c 31else 32if DARWIN_API 33OS_SUPPORT = darwin.c 34AM_CFLAGS_EXT = -no-cpp-precomp 35LDADDS = -Wl,-framework -Wl,IOKit -Wl,-framework -Wl,CoreFoundation -Wl,-prebind -no-undefined 36PREBIND_FLAGS=-Wl,-seg1addr,0x01666000 37PREBIND_FLAGSPP=-Wl,-seg1addr,0x01676000 38else 39OS_SUPPORT = 40endif 41endif 42endif 43 44AM_CFLAGS += $(AM_CFLAGS_EXT) 45 46AM_CPPFLAGS = -I. 47AM_CXXFLAGS = 48 49libusb_la_SOURCES = usb.c usbi.h error.c error.h descriptors.c $(OS_SUPPORT) 50libusbpp_la_SOURCES = usbpp.cpp usbpp.h 51 52libusbpp_la_DEPENDENCIES = libusb.la 53 54# Do not add usb.h to *_SOURCES, regardless of dependencies. 55# It would be added to the dist tarball, which it shouldn't be. 56nodist_include_HEADERS = usb.h 57include_HEADERS = usbpp.h 58 59libusb_la_LDFLAGS = \ 60 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \ 61 -release $(LT_RELEASE) \ 62 -export-dynamic \ 63 $(LDADDS) $(PREBIND_FLAGS) 64 65libusbpp_la_LDFLAGS = \ 66 -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) \ 67 -release $(LT_RELEASE) \ 68 -export-dynamic \ 69 $(LDADDS) -lusb $(PREBIND_FLAGSPP) 70 71.PHONY: files release snapshot 72 73files: 74 @files=`ls $(DISTFILES) 2> /dev/null `; for p in $$files; do \ 75 echo $$p; \ 76 done 77 78release: 79 $(MAKE) distcheck 80 81snapshot: 82 $(MAKE) dist distdir=$(PACKAGE)-`date +"%Y%m%d"` 83 84## generate API documentation with doxygen 85apidox: 86 $(MAKE) apidox-am-@LIBUSB_HAS_DOXYGEN@ 87 88apidox-am-no: 89apidox-am-yes: 90 @echo "*** Creating API documentation main page"; \ 91 doxygen Doxyfile 92 93.PHONY: apidox-am-yes apidox-am-no apidox 94 95