summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorDaniel Drake <dsd@gentoo.org>2007-11-28 13:48:45 +0000
committerDaniel Drake <dsd@gentoo.org>2007-12-02 22:54:59 +0000
commit852bba4754ec57679c823f33e8feba6e4a564cbe (patch)
treecd0a73c5437d1e05799b7bbef047854afdc9939a /configure.ac
downloadlibusb-852bba4754ec57679c823f33e8feba6e4a564cbe.tar.gz
Initial commit
Basic library structure which supports enumerating detected USB devices
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac49
1 files changed, 49 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
new file mode 100644
index 0000000..9829012
--- /dev/null
+++ b/configure.ac
@@ -0,0 +1,49 @@
+AC_INIT([fpusb], [0.0])
+AM_INIT_AUTOMAKE
+AC_CONFIG_SRCDIR([libfpusb/core.c])
+AM_CONFIG_HEADER([config.h])
+
+AC_PREREQ([2.50])
+AC_PROG_CC
+AC_PROG_LIBTOOL
+AC_C_INLINE
+AM_PROG_CC_C_O
+
+# Library versioning
+lt_major="0"
+lt_revision="0"
+lt_age="0"
+AC_SUBST(lt_major)
+AC_SUBST(lt_revision)
+AC_SUBST(lt_age)
+
+# Message logging
+AC_ARG_ENABLE([log], [AS_HELP_STRING([--disable-log], [disable all logging])],
+ [log_enabled=$enableval],
+ [log_enabled='yes'])
+if test "x$log_enabled" != "xno"; then
+ AC_DEFINE([ENABLE_LOGGING], 1, [Message logging])
+fi
+
+AC_ARG_ENABLE([debug-log], [AS_HELP_STRING([--enable-debug-log],
+ [enable debug logging (default n)])],
+ [debug_log_enabled=$enableval],
+ [debug_log_enabled='no'])
+if test "x$debug_log_enabled" != "xno"; then
+ AC_DEFINE([ENABLE_DEBUG_LOGGING], 1, [Debug message logging])
+fi
+
+# Examples build
+AC_ARG_ENABLE([examples-build], [AS_HELP_STRING([--enable-examples-build],
+ [build example applications (default n)])],
+ [build_examples=$enableval],
+ [build_examples='no'])
+AM_CONDITIONAL([BUILD_EXAMPLES], [test "x$build_examples" != "xno"])
+
+AC_DEFINE([API_EXPORTED], [__attribute__((visibility("default")))], [Default visibility])
+AM_CFLAGS="-Werror-implicit-function-declaration -Wimplicit-int -Wunreachable-code -Wunused-function -Wunused-label -Wunused-value -Wunused-variable -Wnonnull -Wreturn-type -Wextra -Wshadow"
+AC_SUBST(AM_CFLAGS)
+
+AC_CONFIG_FILES([fpusb.pc] [Makefile] [libfpusb/Makefile] [examples/Makefile])
+AC_OUTPUT
+