## distdir target by IOhannes m zmölnig
##  portaudio's original build-system lacks a "distdir" target
##  which prevents us from easily creating a distribution tarball
##  for Pd!
##  so we provide a simplified target here, to satisfy autotools needs

# list of all files to be installed
## generated with `make distclean; find . -type f`
DISTFILES=\
	LICENSE.txt \
	include/pa_asio.h \
	include/pa_jack.h \
	include/pa_linux_alsa.h \
	include/pa_mac_core.h \
	include/pa_win_waveformat.h \
	include/pa_win_wmme.h \
	include/portaudio.h \
	src/common/pa_allocation.c \
	src/common/pa_allocation.h \
	src/common/pa_converters.c \
	src/common/pa_converters.h \
	src/common/pa_cpuload.c \
	src/common/pa_cpuload.h \
	src/common/pa_debugprint.c \
	src/common/pa_debugprint.h \
	src/common/pa_dither.c \
	src/common/pa_dither.h \
	src/common/pa_endianness.h \
	src/common/pa_front.c \
	src/common/pa_hostapi.h \
	src/common/pa_memorybarrier.h \
	src/common/pa_process.c \
	src/common/pa_process.h \
	src/common/pa_ringbuffer.c \
	src/common/pa_ringbuffer.h \
	src/common/pa_stream.c \
	src/common/pa_stream.h \
	src/common/pa_trace.c \
	src/common/pa_trace.h \
	src/common/pa_types.h \
	src/common/pa_util.h \
	src/hostapi/alsa/pa_linux_alsa.c \
	src/hostapi/asio/iasiothiscallresolver.cpp \
	src/hostapi/asio/iasiothiscallresolver.h \
	src/hostapi/asio/pa_asio.cpp \
	src/hostapi/coreaudio/notes.txt \
	src/hostapi/coreaudio/pa_mac_core.c \
	src/hostapi/coreaudio/pa_mac_core_blocking.c \
	src/hostapi/coreaudio/pa_mac_core_blocking.h \
	src/hostapi/coreaudio/pa_mac_core_internal.h \
	src/hostapi/coreaudio/pa_mac_core_old.c \
	src/hostapi/coreaudio/pa_mac_core_utilities.c \
	src/hostapi/coreaudio/pa_mac_core_utilities.h \
	src/hostapi/jack/pa_jack.c \
	src/hostapi/oss/low_latency_tip.txt \
	src/hostapi/oss/pa_unix_oss.c \
	src/hostapi/oss/recplay.c \
	src/hostapi/wmme/pa_win_wmme.c \
	src/os/mac_osx/pa_mac_hostapis.c \
	src/os/unix/pa_unix_hostapis.c \
	src/os/unix/pa_unix_util.c \
	src/os/unix/pa_unix_util.h \
	src/os/win/pa_win_coinitialize.c \
	src/os/win/pa_win_coinitialize.h \
	src/os/win/pa_win_hostapis.c \
	src/os/win/pa_win_util.c \
	src/os/win/pa_win_waveformat.c \
	src/os/win/pa_win_wdmks_utils.c \
	src/os/win/pa_win_wdmks_utils.h \
	src/os/win/pa_x86_plain_converters.c \
	src/os/win/pa_x86_plain_converters.h \
	aclocal.m4 \
	configure.in \
	configure \
	Makefile.in \
	Makefile.dist \
	Makefile \
	config.guess \
	config.sub \
	config.status \
	install-sh \
	ltmain.sh

## this is the actual target, stolen from an automake generated Makefile
distdir: $(DISTFILES)
	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
	list='$(DISTFILES)'; \
	  dist_files=`for file in $$list; do echo $$file; done | \
	  sed -e "s|^$$srcdirstrip/||;t" \
	      -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
	case $$dist_files in \
	  */*) $(MKDIR_P) `echo "$$dist_files" | \
	                   sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
	                   sort -u` ;; \
	esac; \
	for file in $$dist_files; do \
	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
	  if test -d $$d/$$file; then \
	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
	    if test -d "$(distdir)/$$file"; then \
	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
	    fi; \
	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
	    fi; \
	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
	  else \
	    test -f "$(distdir)/$$file" \
	    || cp -p $$d/$$file "$(distdir)/$$file" \
	    || exit 1; \
	  fi; \
	done

## some dummy targets,
## that are needed by autotools but are not provided by portaudio
dvi check installcheck distuninstallcheck:
