libschroedinger release.
Contrib: fix fluidsynth distclean target.
CLEAN_FILE += .fluid
CLEAN_PKG += fluidsynth
-DISTCLEAN_PKG += fluidsynth-$(NCURSES_VERSION).tar.gz
+DISTCLEAN_PKG += fluidsynth-$(FLUID_VERSION).tar.gz
+# ***************************************************************************
+# liboil
+# ***************************************************************************
+
+liboil-$(OIL_VERSION).tar.gz:
+ $(WGET) $(OIL_URL)
+
+liboil: liboil-$(OIL_VERSION).tar.gz
+ $(EXTRACT_GZ)
+
+.liboil: liboil
+ (cd $<; $(HOSTCC) ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
+ touch $@
+
+CLEAN_FILE += .liboil
+CLEAN_PKG += liboil
+DISTCLEAN_PKG += liboil-$(OIL_VERSION).tar.gz
+
+# ***************************************************************************
+# Schroedinger library
+# ***************************************************************************
+
+schroedinger-$(SCHROED_VERSION).tar.gz:
+ $(WGET) $(SCHROED_URL)
+
+schroedinger: schroedinger-$(SCHROED_VERSION).tar.gz
+ $(EXTRACT_GZ)
+ patch -d schroedinger -p1 < Patches/libschroedinger-fix-build-OSX.patch
+ patch -d schroedinger -p1 < Patches/libschroedinger-fix-build-OSX-test.patch
+
+.schroedinger: .liboil schroedinger
+ (cd $<; $(HOSTCC) ./configure $(HOSTCONF) --prefix=$(PREFIX) && make && make install)
+ touch $@
+
+CLEAN_FILE += .schroedinger
+CLEAN_PKG += schroedinger
+DISTCLEAN_PKG += schroedinger-$(SCHROED_VERSION).tar.gz
# ***************************************************************************
# Some cleaning
--- /dev/null
+From: David Schleef <ds@hutch.local>
+Date: Mon, 23 Jun 2008 20:24:34 +0000 (-0700)
+Subject: [build] Remove i386-only test. not useful.
+X-Git-Url: http://diracvideo.org/git?p=schroedinger.git;a=commitdiff_plain;h=03a9d4cee3c42715a5b7370d7a62f3d788c77e2a
+
+[build] Remove i386-only test. not useful.
+---
+
+diff --git a/testsuite/prototype/Makefile.am b/testsuite/prototype/Makefile.am
+index 0513faf..8b13789 100644
+--- a/testsuite/prototype/Makefile.am
++++ b/testsuite/prototype/Makefile.am
+@@ -1,11 +1 @@
+
+-if HAVE_I386
+-noinst_PROGRAMS = arith_speed
+-endif
+-
+-AM_CFLAGS = $(SCHRO_CFLAGS) $(ERROR_CFLAGS) $(LIBOIL_CFLAGS) \
+- -DSCHRO_ENABLE_UNSTABLE_API
+-LDADD = $(SCHRO_LIBS)
+-
+-arith_speed_SOURCES = arith_speed.c
+-
--- /dev/null
+From: David Schleef <ds@ginger.bigkitten.com>
+Date: Tue, 10 Jun 2008 18:48:06 +0000 (-0700)
+Subject: [core] Check number of processors correctly on OS/X. Patch from
+X-Git-Url: http://diracvideo.org/git?p=schroedinger.git;a=commitdiff_plain;h=7e125aa636e520393ebf8e9315d3956e399f4175
+
+[core] Check number of processors correctly on OS/X. Patch from
+Karl Rasche <karlrasche@gmail.com>
+---
+
+diff --git a/schroedinger/schroasync-pthread.c b/schroedinger/schroasync-pthread.c
+index 3a975e0..60bf1c1 100644
+--- a/schroedinger/schroasync-pthread.c
++++ b/schroedinger/schroasync-pthread.c
+@@ -13,6 +13,10 @@
+ #include <sys/time.h>
+ #include <time.h>
+
++#ifdef __APPLE__
++#include <sys/sysctl.h>
++#endif
++
+ enum {
+ STATE_IDLE,
+ STATE_BUSY,
+@@ -79,14 +83,23 @@ schro_async_new(int n_threads,
+ }
+ }
+ if (n_threads == 0) {
+-#ifndef _WIN32
+- n_threads = sysconf(_SC_NPROCESSORS_CONF);
+-#else
++#ifdef _WIN32
+ const char *s = getenv("NUMBER_OF_PROCESSORS");
+ if (s) {
+ n_threads = atoi(s);
+ }
+-#endif
++#elif defined __APPLE__
++ {
++ int mib[] = {CTL_HW, HW_NCPU};
++ size_t dataSize = sizeof(int);
++
++ if (sysctl(mib, 2, &n_threads, &dataSize, NULL, 0)) {
++ n_threads = 0;
++ }
++ }
++#else
++ n_threads = sysconf(_SC_NPROCESSORS_CONF);
++#endif
+ }
+ if (n_threads == 0) {
+ n_threads = 1;
YASM_VERSION=0.7.0
YASM_URL=$(VIDEOLAN)/testing/contrib/yasm-$(YASM_VERSION).tar.gz
#YASM_URL=http://www.tortall.net/projects/yasm/releases/yasm-$(YASM_VERSION).tar.gz
+OIL_VERSION=0.3.14
+OIL_URL=http://liboil.freedesktop.org/download/liboil-$(OIL_VERSION).tar.gz
+SCHROED_VERSION=1.0.3
+SCHROED_URL=http://www.diracvideo.org/download/schroedinger/schroedinger-$(SCHROED_VERSION).tar.gz