summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
Diffstat (limited to 'Modules')
-rwxr-xr-xModules/makesetup13
1 files changed, 11 insertions, 2 deletions
diff --git a/Modules/makesetup b/Modules/makesetup
index 9046657..7547315 100755
--- a/Modules/makesetup
+++ b/Modules/makesetup
@@ -31,6 +31,7 @@
# - insert an identifying comment at the start
# - replace _MODBUILT_NAMES_ by the list of *static* and *shared* modules
# from Setup
+# - replace _MODBSHARED_NAMES_ by the list of *shared* modules from Setup
# - replace _MODDISABLED_NAMES_ by the list of *disabled* modules from Setup
# - replace _MODOBJS_ by the list of objects from Setup (except for
# Setup files after a -n option)
@@ -114,6 +115,7 @@ sed -e 's/[ ]*#.*//' -e '/^[ ]*$/d' |
" >$rulesf
DEFS=
BUILT=
+ BUILT_SHARED=
DISABLED=
MODS=
SHAREDMODS=
@@ -222,7 +224,10 @@ sed -e 's/[ ]*#.*//' -e '/^[ ]*$/d' |
*.m) obj=`basename $src .m`.o; cc='$(CC)';; # Obj-C
*) continue;;
esac
- obj="$srcdir/$obj"
+ case $src in
+ */*) obj="$srcdir/`dirname $src`/$obj";;
+ *) obj="$srcdir/$obj";;
+ esac
objs="$objs $obj"
case $src in
glmodule.c) ;;
@@ -246,7 +251,10 @@ sed -e 's/[ ]*#.*//' -e '/^[ ]*$/d' |
do
file="$srcdir/$mod\$(EXT_SUFFIX)"
case $doconfig in
- no) SHAREDMODS="$SHAREDMODS $file";;
+ no)
+ SHAREDMODS="$SHAREDMODS $file"
+ BUILT_SHARED="$BUILT_SHARED $mod"
+ ;;
esac
rule="$file: $objs"
rule="$rule; \$(BLDSHARED) $objs $libs $ExtraLibs -o $file"
@@ -296,6 +304,7 @@ sed -e 's/[ ]*#.*//' -e '/^[ ]*$/d' |
str="# Generated automatically from $makepre by makesetup."
echo "$str" >>$sedf
echo "s%_MODBUILT_NAMES_%$BUILT%" >>$sedf
+ echo "s%_MODSHARED_NAMES_%$BUILT_SHARED%" >>$sedf
echo "s%_MODDISABLED_NAMES_%$DISABLED%" >>$sedf
echo "s%_MODOBJS_%$OBJS%" >>$sedf
echo "s%_MODLIBS_%$LIBS%" >>$sedf