--- /dev/null
+## Process this file with automake to produce Makefile.in. -*-Makefile-*-
+# inspired from Guenter Geiger's Makefile.am for plugin
+# pure-data/externals/plugin~/Makefile.am -- rev 1.1
+
+pddir = $(prefix)/lib/pd
+
+## Make and install the shared library.
+pdinstalldir = $(pddir)/extra
+pdinstallrefdir = $(pddir)/doc/5.reference
+pdinstallexpdir = $(pddir)/doc/aubio
+
+if MINGW
+PDEXT = aubio.dll
+else
+if DARWIN
+PDEXT = aubio.pd_darwin
+else
+PDEXT = aubio.pd_linux
+endif
+endif
+
+pdinstall_PROGRAMS = $(PDEXT)
+
+ALLSOURCES = \
+ aubio_setup.c \
+ aubioonset~.c \
+ aubiotempo~.c \
+ aubiotss~.c \
+ aubioquiet~.c \
+ aubiopitch~.c \
+ aubiozcr~.c
+
+aubio_pd_linux_SOURCES = $(ALLSOURCES)
+aubio_pd_darwin_SOURCES = $(ALLSOURCES)
+aubio_dll_SOURCES = $(ALLSOURCES)
+
+pdincludedir = $(pddir)/src
+
+AM_CFLAGS = -I$(top_srcdir)/src -I$(pdincludedir) -DPD @AUBIO_CFLAGS@
+if MINGW
+else
+AM_CFLAGS += -fPIC -DPIC
+endif
+
+AM_LDFLAGS = -L$(top_builddir)/src @AUBIO_LIBS@
+if MINGW
+AM_LDFLAGS += -export_dynamic -shared -lpd
+else
+if DARWIN
+AM_LDFLAGS += -bundle -undefined suppress -flat_namespace
+else
+AM_LDFLAGS += --export_dynamic --shared
+endif
+endif
+
+## Install the documentation.
+
+pdinstallref_DATA = \
+ help/aubioonset~-help.pd \
+ help/aubioquiet~-help.pd \
+ help/aubiotempo~-help.pd \
+ help/aubiotss~-help.pd \
+ help/aubiopitch~-help.pd
+
+pdinstallexp_DATA = \
+ examples/onset-cam.pd
+
+EXTRA_DIST = $(pdinstallref_DATA) $(pdinstallexp_DATA)
--- /dev/null
+dnl Process this file with autoconf to produce a configure script
+
+dnl Init autoconf
+AC_INIT([pd-aubio], [0.0.1])
+AC_CONFIG_SRCDIR([aubio_setup.c])
+
+dnl Init automake
+AM_INIT_AUTOMAKE([dist-bzip2 no-define])
+
+dnl Check for Puredata
+AC_CHECK_HEADER([m_pd.h],PUREDATA=y,AC_MSG_WARN([Puredata header not found.]))
+AM_CONDITIONAL(PUREDATAFOUND, test "${PUREDATA}" = "y")
+
+dnl Check for pkg-config
+AC_PATH_PROG(PKG_CONFIG,pkg-config,no)
+
+dnl Check for aubio
+PKG_CHECK_MODULES(AUBIO, aubio >= 0.4.0, HAVE_AUBIO=1)
+
+AM_CONDITIONAL(MINGW, false)
+AM_CONDITIONAL(DARWIN, false)
+case "${host}" in
+*mingw* | *cygwin*)
+ mingw32_support="yes"
+ AC_CHECK_HEADER(windows.h)
+ AM_CONDITIONAL(MINGW, true)
+ LDFLAGS="$LDFLAGS -no-undefined"
+ ;;
+*darwin* | *rhapsody* | *macosx*)
+ AC_ISC_POSIX
+ AM_CONDITIONAL(DARWIN, true)
+ ;;
+*)
+ AC_ISC_POSIX
+ ;;
+esac
+
+dnl Create Makefiles
+AC_OUTPUT([
+ Makefile
+])