Hi,
could someone give me a hint how to compile a single-file c-source external ("externals/vbap/rvbap.c" to be honest) on Debian for Windows? I installed the three mingw32 packages, but I'm not clear how to actually use these to compile rvbap.dll
Maybe someone has a Makefile-snippet somewhere and could post it.
By trial and error I managed to compile the *.o file using:
$ i586-mingw32msvc-cc -DPD -O3 -funroll-loops -fomit-frame-pointer -ICVS/pd/src -W -ggdb -D_WINDOWS -fPIC -o "rvbap.o" -c "rvbap.c"
But then linking fails:
$ i586-mingw32msvc-cc -Wl,-export_dynamic -shared -o "rvbap.dll" "rvbap.o" \ -lm -lc /usr/lib/gcc/i586-mingw32msvc/3.4.5/../../../../i586-mingw32msvc/bin/ld: cannot find -lc collect2: ld returned 1 exit status
libc6-dev is installed, am I missing something else?
Ciao
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
could someone give me a hint how to compile a single-file c-source external ("externals/vbap/rvbap.c" to be honest) on Debian for Windows? I installed the three mingw32 packages, but I'm not clear how to actually use these to compile rvbap.dll
Maybe someone has a Makefile-snippet somewhere and could post it.
Hm, I got a bit further along with this by using the Makefile from Guenther's build system (which looks a bit easier to exploit than the huge extended Makefiles for now).
Now I get this:
$ CC=i586-mingw32msvc-cc make -f Makefile.mingw rvbap.dll i586-mingw32msvc-cc -mms-bitfields -Wall -W -Wshadow -Wstrict-prototypes -Wno-unused -Wno-parentheses -Wno-switch -O3 -march=i686 -mfpmath=sse -msse -DPD -DNT -D'drand48()=((double)rand()/RAND_MAX)' -D'srand48(n)=srand((n))' -D'O_NONBLOCK=1' -I. -I.. -I../../pd/src -IC:/msys/1.0/include \ -o "rvbap.o" -c "rvbap.c" i586-mingw32msvc-cc -shared -LC:/msys/1.0/lib -L../../pd/bin -lpd -o "rvbap.dll" "rvbap.o" \ `test -f rvbap.libs && cat rvbap.libs` \ `test -f rvbap.libs && cat rvbap.libs` /usr/lib/gcc/i586-mingw32msvc/3.4.5/../../../../i586-mingw32msvc/bin/ld: cannot find -lpd collect2: ld returned 1 exit status make: *** [rvbap.dll] Error 1
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
Now this sounds like a much bigger task. My first try failed at m_sched.c, which is not finding pthread.h
I configured Pd with "./configure --host=i586-mingw32msvc --target=i586-mingw32msvc".
As the clock is ticking for me, I would be really thankful if someone with a working Windows-compilation-setup could compile rvbap.dll for me. I would offer a really big beer for this, if I can get a hold of rvbap.dll before tomorrow, tuesday, 15:00 GMT+1. ;)
Ciao
Frank Barknecht wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
could someone give me a hint how to compile a single-file c-source external ("externals/vbap/rvbap.c" to be honest) on Debian for Windows? I installed the three mingw32 packages, but I'm not clear how to actually use these to compile rvbap.dll
Maybe someone has a Makefile-snippet somewhere and could post it.
Hm, I got a bit further along with this by using the Makefile from Guenther's build system (which looks a bit easier to exploit than the huge extended Makefiles for now).
Now I get this:
$ CC=i586-mingw32msvc-cc make -f Makefile.mingw rvbap.dll i586-mingw32msvc-cc -mms-bitfields -Wall -W -Wshadow -Wstrict-prototypes -Wno-unused -Wno-parentheses -Wno-switch -O3 -march=i686 -mfpmath=sse -msse -DPD -DNT -D'drand48()=((double)rand()/RAND_MAX)' -D'srand48(n)=srand((n))' -D'O_NONBLOCK=1' -I. -I.. -I../../pd/src -IC:/msys/1.0/include \ -o "rvbap.o" -c "rvbap.c" i586-mingw32msvc-cc -shared -LC:/msys/1.0/lib -L../../pd/bin -lpd -o "rvbap.dll" "rvbap.o" \ `test -f rvbap.libs && cat rvbap.libs` \ `test -f rvbap.libs && cat rvbap.libs` /usr/lib/gcc/i586-mingw32msvc/3.4.5/../../../../i586-mingw32msvc/bin/ld: cannot find -lpd collect2: ld returned 1 exit status make: *** [rvbap.dll] Error 1
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
(I thought libc was included by default with gcc, you didn't need -lc). You need pd.lib, which is in pd/bin. If you just take Miller's pd for Windows it will be inside. The thing I'm still not clear on is if you can use that pd.lib, which was compiled with MSVC, with MinGW... I still haven't got MinGW set up to compile pd. It was a lot easier to set up MSVC, but I'm not cross-compiling.
Now this sounds like a much bigger task. My first try failed at m_sched.c, which is not finding pthread.h
I configured Pd with "./configure --host=i586-mingw32msvc --target=i586-mingw32msvc".
As the clock is ticking for me, I would be really thankful if someone with a working Windows-compilation-setup could compile rvbap.dll for me. I would offer a really big beer for this, if I can get a hold of rvbap.dll before tomorrow, tuesday, 15:00 GMT+1. ;)
I could do it for you with MSVC, but as I said, I don't know if it will work.
Martin
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
Hm, sorry for talking to myself, but it seems I could use a pre-compiled binary from Miller's site (I would have preferred a to use a current pd-extended compiled with GCC, but I couldn't find a zip-file. Are there only installers?)
Anyways with pointing gcc to the pd.dll inside of that, rvbap.dll finally built and I could even load it running pd.exe with Wine.
Seems I'll drink the beer on my own. ;)
Ciao
Frank Barknecht wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
Hm, sorry for talking to myself, but it seems I could use a pre-compiled binary from Miller's site (I would have preferred a to use a current pd-extended compiled with GCC, but I couldn't find a zip-file. Are there only installers?)
Anyways with pointing gcc to the pd.dll inside of that, rvbap.dll finally built and I could even load it running pd.exe with Wine.
Seems I'll drink the beer on my own. ;)
argh...too late
mfg.asdr IOhannes
Frank Barknecht wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
Hm, sorry for talking to myself, but it seems I could use a pre-compiled binary from Miller's site (I would have preferred a to use a current pd-extended compiled with GCC, but I couldn't find a zip-file. Are there only installers?)
to my knowledge, this is true. however, wine is your friend (at least it is mine)
mfg.asdr IOhannes
On Mon, 22 Jan 2007 15:46:38 +0100 Frank Barknecht fbar@footils.org wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
Hm, sorry for talking to myself, but it seems I could use a pre-compiled binary from Miller's site (I would have preferred a to use a current pd-extended compiled with GCC, but I couldn't find a zip-file. Are there only installers?)
Hi Frank, I was just following your monologue there and wondering, what is rvbap ?
Andy
Anyways with pointing gcc to the pd.dll inside of that, rvbap.dll finally built and I could even load it running pd.exe with Wine.
Seems I'll drink the beer on my own. ;)
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-dev mailing list PD-dev@iem.at http://lists.puredata.info/listinfo/pd-dev
Hallo, padawan12 hat gesagt: // padawan12 wrote:
Hi Frank, I was just following your monologue there and wondering, what is rvbap ?
It's an extension of the vbap-external which does advanced multichannel panning. You can find it in the CVS at externals/vbap. It's already part of the 0.40 autobuilds, but there is no Windows autobuild yet, that's why I'm trying to compile on my own.
And to answer a possible next question: Why am *I* of all people trying to build a Windows binary? It's for this performance tomorrow: http://www.khm.de/news/news2007/nocturne10.htm and because the RME HDSP I borrowed doesn't like my laptop at all, I'm using a borrowed Windows machine for the actual spatialization but at least controlled from my Linux laptop through netsend. ;)
Ciao
Frank Barknecht wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
/usr/lib/gcc/i586-mingw32msvc/3.4.5/../../../../i586-mingw32msvc/bin/ld: cannot find -lpd collect2: ld returned 1 exit status make: *** [rvbap.dll] Error 1
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
yes and no. you do need to link against pd.lib you don't need to crosscompile. just get a binary-version for w32 of pd (i usually use miller's pd) and add the path to the pd.lib to your linker-flags: "-L/tmp/w32/pd/bin"
As the clock is ticking for me, I would be really thankful if someone with a working Windows-compilation-setup could compile rvbap.dll for me. I would offer
iemmatrix comes with explanations on how to cross-compile it on debian for w32.
a really big beer for this, if I can get a hold of rvbap.dll before tomorrow, tuesday, 15:00 GMT+1. ;)
forget everything i wrote above. and wait a minute :-)
mfgadsr .IOhannes
Ciao
Hallo, IOhannes m zmoelnig hat gesagt: // IOhannes m zmoelnig wrote:
yes and no. you do need to link against pd.lib you don't need to crosscompile. just get a binary-version for w32 of pd (i usually use miller's pd) and add the path to the pd.lib to your linker-flags: "-L/tmp/w32/pd/bin"
Actually this is about what I did now. I used attached Makefile.mingw, where I just set PD_PATH to where I unpacked Miller's 0.39 zipfile, then I compiled with:
$ CC=i586-mingw32msvc-cc make rvbap.dll
iemmatrix comes with explanations on how to cross-compile it on debian for w32.
Ah, cool. I'll check this out anyways.
forget everything i wrote above. and wait a minute :-)
Well, so far my dll is only tested on Wine, the real Windows test (with a pd-extended binary) should happen soonish, I guess, and if it fails, Martin and you get another chance. ;)
Ciao
On Jan 22, 2007, at 9:13 AM, Frank Barknecht wrote:
Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote:
could someone give me a hint how to compile a single-file c-source external ("externals/vbap/rvbap.c" to be honest) on Debian for Windows? I installed the three mingw32 packages, but I'm not clear how to actually use these to compile rvbap.dll
Maybe someone has a Makefile-snippet somewhere and could post it.
Hm, I got a bit further along with this by using the Makefile from Guenther's build system (which looks a bit easier to exploit than the huge extended Makefiles for now).
Now I get this:
$ CC=i586-mingw32msvc-cc make -f Makefile.mingw rvbap.dll i586-mingw32msvc-cc -mms-bitfields -Wall -W -Wshadow -Wstrict- prototypes -Wno-unused -Wno-parentheses -Wno-switch -O3 -march=i686 -mfpmath=sse -msse -DPD -DNT -D'drand48()=((double)rand()/ RAND_MAX)' -D'srand48(n)=srand((n))' -D'O_NONBLOCK=1' -I. -I.. - I../../pd/src -IC:/msys/1.0/include \ -o "rvbap.o" -c "rvbap.c" i586-mingw32msvc-cc -shared -LC:/msys/1.0/lib -L../../pd/bin -lpd - o "rvbap.dll" "rvbap.o" \ `test -f rvbap.libs && cat rvbap.libs` \ `test -f rvbap.libs && cat rvbap.libs` /usr/lib/gcc/i586-mingw32msvc/3.4.5/../../../../i586-mingw32msvc/ bin/ld: cannot find -lpd collect2: ld returned 1 exit status make: *** [rvbap.dll] Error 1
Oops, do I read this correctly, that on Windows (or *for* Windows) I need to have some kind of pd.dll to compile an external? And that means, I need to cross-compile Pd first?
Now this sounds like a much bigger task. My first try failed at m_sched.c, which is not finding pthread.h
I configured Pd with "./configure --host=i586-mingw32msvc -- target=i586-mingw32msvc".
As the clock is ticking for me, I would be really thankful if someone with a working Windows-compilation-setup could compile rvbap.dll for me. I would offer a really big beer for this, if I can get a hold of rvbap.dll before tomorrow, tuesday, 15:00 GMT+1. ;)
vbap is already compiled on Windows using externals/Makefile, so you don't need to rewrite or change anything. If you need to change CFLAGS, then you can do that like this:
cd pure-data/externals make CFLAGS="-whatever -something else" vbap
.hc
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-dev mailing list PD-dev@iem.at http://lists.puredata.info/listinfo/pd-dev
------------------------------------------------------------------------
I spent 33 years and four months in active military service and during that period I spent most of my time as a high class muscle man for Big Business, for Wall Street and the bankers. - General Smedley Butler
Hallo, Hans-Christoph Steiner hat gesagt: // Hans-Christoph Steiner wrote:
vbap is already compiled on Windows using externals/Makefile, so you don't need to rewrite or change anything. If you need to change CFLAGS, then you can do that like this:
cd pure-data/externals make CFLAGS="-whatever -something else" vbap
Note that I was trying to build a *Windows* binary on *Linux*, as I don't have Windows.
I had already tried:
$ cd pure-data/externals $ CC=i586-mingw32msvc-cc make vbap
but this tries to build the linux version with the cross-compiler for Windows, which of course isn't what I want. Explicitely specifying what to build doesn't seem to work either:
$ CC=i586-mingw32msvc-cc make vbap/rvbap.dll make: *** No rule to make target `vbap/rvbap.dll'. Stop.
Is there a way to set the target/host system with some CFLAGS using the extended-Makefile?
Ciao
On Jan 27, 2007, at 1:51 PM, Frank Barknecht wrote:
Hallo, Hans-Christoph Steiner hat gesagt: // Hans-Christoph Steiner wrote:
vbap is already compiled on Windows using externals/Makefile, so you don't need to rewrite or change anything. If you need to change CFLAGS, then you can do that like this:
cd pure-data/externals make CFLAGS="-whatever -something else" vbap
Note that I was trying to build a *Windows* binary on *Linux*, as I don't have Windows.
I had already tried:
$ cd pure-data/externals $ CC=i586-mingw32msvc-cc make vbap
but this tries to build the linux version with the cross-compiler for Windows, which of course isn't what I want. Explicitely specifying what to build doesn't seem to work either:
$ CC=i586-mingw32msvc-cc make vbap/rvbap.dll make: *** No rule to make target `vbap/rvbap.dll'. Stop.
Is there a way to set the target/host system with some CFLAGS using the extended-Makefile?
All of the platform-specific settings are determined by the varible $ (OS_NAME). Normally it is set in packages/Makefile.buildlayout using the result of uname. I think this should work then:
make CC=i586-mingw32msvc-cc OS_NAME=windows vbap
But you'd be the first to try, so there might be bugs.
.hc
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-dev mailing list PD-dev@iem.at http://lists.puredata.info/listinfo/pd-dev
------------------------------------------------------------------------
As we enjoy great advantages from inventions of others, we should be glad of an opportunity to serve others by any invention of ours; and this we should do freely and generously. - Benjamin Franklin