Hi lists,
Perhaps this is a little ot, but I try to compile some externals from
linux (ubuntu edgy) to windows.
I've installed the mingw32 packages and edited my makefile to replace
the "cc" and "ld" commands by the "i586-mingw32msvc-" ,"cc" and "ld"
ones when I choose pd_nt as a target. I also add the "-L/usr/lib/"
option to the "i586-mingw32msvc-ld".
Here is the concerned part of the makefile :
-------------
pd_nt: downquantize~.dll
.SUFFIXES: .dll
PDNTCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer \
-Wall -W -Wshadow -Wstrict-prototypes -Werror \
-Wno-unused -Wno-parentheses -Wno-switch
PDNTINCLUDE = -I/home/montgermont/pd/pd-0.40-0test05/src -I/usr/include/stk
.c.dll:
i586-mingw32msvc-cc $(PDNTCFLAGS) $(PDNTINCLUDE) -o $*.o -c $*.c
i586-mingw32msvc-ld -export_dynamic -L/usr/lib/ -shared -o $*.dll
$*.o -lc -lm -lstk
strip --strip-unneeded $*.dll
rm $*.o
-------------------------
and here is the terminal error:
-------------------------
[EMAIL PROTECTED]:~/pd/downquantize$ make pd_nt
i586-mingw32msvc-cc -DPD -O2 -funroll-loops -fomit-frame-pointer -Wall
-W -Wshadow -Wstrict-prototypes -Werror -Wno-unused -Wno-parentheses
-Wno-switch -I/home/montgermont/pd/pd-0.40-0test05/src
-I/usr/include/stk -o downquantize~.o -c downquantize~.c
i586-mingw32msvc-ld -export_dynamic -L/usr/lib/ -shared -o
downquantize~.dll downquantize~.o -lc -lm -lstk
downquantize~.o:downquantize~.c:(.text+0x284): référence indéfinie vers
« dsp_add »
downquantize~.o:downquantize~.c:(.text+0x29b): référence indéfinie vers
« pd_new »
downquantize~.o:downquantize~.c:(.text+0x2b1): référence indéfinie vers
« floatinlet_new »
downquantize~.o:downquantize~.c:(.text+0x2b8): référence indéfinie vers
« s_signal »
downquantize~.o:downquantize~.c:(.text+0x2be): référence indéfinie vers
« outlet_new »
downquantize~.o:downquantize~.c:(.text+0x2e8): référence indéfinie vers
« gensym »
downquantize~.o:downquantize~.c:(.text+0x2f0): référence indéfinie vers
« class_new »
downquantize~.o:downquantize~.c:(.text+0x306): référence indéfinie vers
« gensym »
downquantize~.o:downquantize~.c:(.text+0x31b): référence indéfinie vers
« class_addmethod »
downquantize~.o:downquantize~.c:(.text+0x32a): référence indéfinie vers
« class_domainsignalin »
make: *** [downquantize~.dll] Erreur 1
--------------------------
It seems mingw32msvc can't find any pd function... but the linux to
linux part works well (see attached)
Do someone understand where is the error? Or better, already have a
makefile to cross compile?
Sorry if it's stupid, I'm not really used to makefiles...
Greetings,
--
Nicolas Montgermont
http://nicomon.basseslumieres.org
current: pd_linux
# ----------------------- NT -----------------------
pd_nt: downquantize~.dll
.SUFFIXES: .dll
PDNTCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer \
-Wall -W -Wshadow -Wstrict-prototypes -Werror \
-Wno-unused -Wno-parentheses -Wno-switch
PDNTINCLUDE = -I/home/montgermont/pd/pd-0.40-0test05/src -I/usr/include/stk
.c.dll:
i586-mingw32msvc-cc $(PDNTCFLAGS) $(PDNTINCLUDE) -o $*.o -c $*.c
i586-mingw32msvc-ld -export_dynamic -L/usr/lib/ -shared -o $*.dll $*.o
-lc -lm -lstk
strip --strip-unneeded $*.dll
rm $*.o
# ----------------------- LINUX i386 -----------------------
pd_linux: downquantize~.pd_linux
.SUFFIXES: .pd_linux
LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer \
-Wall -W -Wshadow -Wstrict-prototypes -Werror \
-Wno-unused -Wno-parentheses -Wno-switch
LINUXINCLUDE = -I/home/montgermont/pd/pd-0.40-0test05/src -I/usr/include/stk
.c.pd_linux:
cc $(LINUXCFLAGS) $(LINUXINCLUDE) -o $*.o -c $*.c
ld -export_dynamic -shared -o $*.pd_linux $*.o -lc -lm -lstk
strip --strip-unneeded $*.pd_linux
rm $*.o
# ----------------------- Mac OSX -----------------------
d_ppc: $(NAME).d_ppc
d_fat: $(NAME).d_fat
.SUFFIXES: .d_ppc .d_fat
DARWINCFLAGS = -DPD -O2 -Wall -W -Wshadow -Wstrict-prototypes \
-Wno-unused -Wno-parentheses -Wno-switch
.c.d_ppc:
$(CC) $(DARWINCFLAGS) $(LINUXINCLUDE) -o $*.o -c $*.c
$(CC) -bundle -undefined suppress -flat_namespace -o $*.pd_darwin $*.o
rm -f $*.o
.c.d_fat:
$(CC) -arch i386 -arch ppc $(DARWINCFLAGS) $(LINUXINCLUDE) -o $*.o -c
$*.c
$(CC) -arch i386 -arch ppc -bundle -undefined suppress -flat_namespace \
-o $*.d_fat $*.o
rm -f $*.o
# ----------------------------------------------------------
clean:
rm -f *.o *.pd_* so_locations
_______________________________________________
PD-dev mailing list
[email protected]
http://lists.puredata.info/listinfo/pd-dev