diff --git a/libc3/configure b/libc3/configure
index 13556fb..00e869b 100755
--- a/libc3/configure
+++ b/libc3/configure
@@ -110,5 +110,4 @@ update_build_lib
build_lo
build_lib
-
update_config_mk
diff --git a/libc3_window/cairo/quartz/configure b/libc3_window/cairo/quartz/configure
index a76ca69..c8f75b0 100755
--- a/libc3_window/cairo/quartz/configure
+++ b/libc3_window/cairo/quartz/configure
@@ -169,4 +169,5 @@ done
update_config_mk
env_reset
-( cd demo && ./configure; )
+
+config_subdirs demo
diff --git a/libc3_window/sdl2/demo/configure b/libc3_window/sdl2/demo/configure
index 91c16df..681d5a2 100755
--- a/libc3_window/sdl2/demo/configure
+++ b/libc3_window/sdl2/demo/configure
@@ -154,10 +154,13 @@ echo "" >> ${CONFIG_MK}
if [ "x$(uname)" = "xDarwin" ]; then
HAVE_DARWIN=true
- (cd macos && ./configure; )
else
HAVE_DARWIN=false
fi
echo "HAVE_DARWIN = $HAVE_DARWIN" >> ${CONFIG_MK}
update_config_mk
+
+if ${HAVE_DARWIN}; then
+ config_subdirs macos
+fi
diff --git a/libc3_window/sdl2/demo/macos/configure b/libc3_window/sdl2/demo/macos/configure
index 4e2bf6d..04da01a 100755
--- a/libc3_window/sdl2/demo/macos/configure
+++ b/libc3_window/sdl2/demo/macos/configure
@@ -15,7 +15,7 @@ set -e
export SRC_TOP="$(dirname "$PWD")"
-. ../../../../../config.subr
+. ../../../../config.subr
PROG=c3_window_sdl2_demo
PROG_ASAN=c3_window_sdl2_demo_asan
@@ -54,7 +54,7 @@ echo " cp ../.libs/${PROG} ${APP_PROG}" >> ${CONFIG_MK}
BUNDLE_LIBS_COMMON="/usr/local/lib/libSDL2-2.0.0.dylib"
-BUNDLE_LIBS="${BUNDLE_LIBS_COMMON} ../../../../.libs/libc3.0.dylib ../../../.libs/libc3_window.0.dylib ../../.libs/libc3_window_sdl2.0.dylib"
+BUNDLE_LIBS="${BUNDLE_LIBS_COMMON} ../../../../libc3/.libs/libc3.0.dylib ../../../.libs/libc3_window.0.dylib ../../.libs/libc3_window_sdl2.0.dylib"
echo >> ${CONFIG_MK}
echo "${APP}/Contents/Frameworks: ${BUNDLE_LIBS}" >> ${CONFIG_MK}
echo " mkdir -p ${APP}/Contents/Frameworks" >> ${CONFIG_MK}
@@ -74,7 +74,7 @@ echo "${APP_PROG_ASAN}: ../.libs/${PROG_ASAN}" >> ${CONFIG_MK}
echo " mkdir -p ${APP_ASAN}/Contents/MacOS" >> ${CONFIG_MK}
echo " cp ../.libs/${PROG_ASAN} ${APP_PROG_ASAN}" >> ${CONFIG_MK}
-BUNDLE_LIBS_ASAN="${BUNDLE_LIBS_COMMON} ../../../../.libs/libc3_asan.0.dylib ../../../.libs/libc3_window_asan.0.dylib ../../.libs/libc3_window_sdl2_asan.0.dylib"
+BUNDLE_LIBS_ASAN="${BUNDLE_LIBS_COMMON} ../../../../libc3/.libs/libc3_asan.0.dylib ../../../.libs/libc3_window_asan.0.dylib ../../.libs/libc3_window_sdl2_asan.0.dylib"
echo >> ${CONFIG_MK}
echo "${APP_ASAN}/Contents/Frameworks: ${BUNDLE_LIBS_ASAN}" >> ${CONFIG_MK}
echo " mkdir -p ${APP_ASAN}/Contents/Frameworks" >> ${CONFIG_MK}
@@ -94,7 +94,7 @@ echo "${APP_PROG_COV}: ../.libs/${PROG_COV}" >> ${CONFIG_MK}
echo " mkdir -p ${APP_COV}/Contents/MacOS" >> ${CONFIG_MK}
echo " cp ../.libs/${PROG_COV} ${APP_PROG_COV}" >> ${CONFIG_MK}
-BUNDLE_LIBS_COV="${BUNDLE_LIBS_COMMON} ../../../../.libs/libc3_cov.0.dylib ../../../.libs/libc3_window_cov.0.dylib ../../.libs/libc3_window_sdl2_cov.0.dylib"
+BUNDLE_LIBS_COV="${BUNDLE_LIBS_COMMON} ../../../../libc3/.libs/libc3_cov.0.dylib ../../../.libs/libc3_window_cov.0.dylib ../../.libs/libc3_window_sdl2_cov.0.dylib"
echo >> ${CONFIG_MK}
echo "${APP_COV}/Contents/Frameworks: ${BUNDLE_LIBS_COV}" >> ${CONFIG_MK}
echo " mkdir -p ${APP_COV}/Contents/Frameworks" >> ${CONFIG_MK}
@@ -114,7 +114,7 @@ echo "${APP_PROG_DEBUG}: ../.libs/${PROG_DEBUG}" >> ${CONFIG_MK}
echo " mkdir -p ${APP_DEBUG}/Contents/MacOS" >> ${CONFIG_MK}
echo " cp ../.libs/${PROG_DEBUG} ${APP_PROG_DEBUG}" >> ${CONFIG_MK}
-BUNDLE_LIBS_DEBUG="${BUNDLE_LIBS_COMMON} ../../../../.libs/libc3_debug.0.dylib ../../../.libs/libc3_window_debug.0.dylib ../../.libs/libc3_window_sdl2_debug.0.dylib"
+BUNDLE_LIBS_DEBUG="${BUNDLE_LIBS_COMMON} ../../../../libc3/.libs/libc3_debug.0.dylib ../../../.libs/libc3_window_debug.0.dylib ../../.libs/libc3_window_sdl2_debug.0.dylib"
echo >> ${CONFIG_MK}
echo "${APP_DEBUG}/Contents/Frameworks: ${BUNDLE_LIBS_DEBUG}" >> ${CONFIG_MK}
echo " mkdir -p ${APP_DEBUG}/Contents/Frameworks" >> ${CONFIG_MK}