[ecasound] Porting ecawave to FreeBSD

New Message Reply Date view Thread view Subject view Author view Other groups

Subject: [ecasound] Porting ecawave to FreeBSD
From: Anarcat (beaupran@IRO.UMontreal.CA)
Date: Thu Dec 21 2000 - 03:51:51 EET


So. Back to my starting point. :)

bash-2.04$ pwd
/u/anarcat/src/contrib/ecawave-0.3.3d3
bash-2.04$ ./configure
loading cache ./config.cache
[...]
checking for a BSD compatible install... /usr/bin/install -c
checking for main in -lecasound... no
configure: error: ** libecasound not installed/found **
bash-2.04$ tail config.log
configure:1395: checking for main in -lecasound
configure:1410: gcc -o conftest -g -O2 conftest.c -lecasound -lkvutils 1>&5
/usr/libexec/elf/ld: cannot find -lecasound
configure: failed program was:
#line 1403 "configure"
#include "confdefs.h"

int main() {
main()
; return 0; }
bash-2.04$

Marvelous. ldconfig was run. Lib is in the ldpath:

bash-2.04$ ldconfig -r | grep ecas
        232:-lecasound.7 => /usr/local/lib/libecasound.so.7
        254:-lecasoundc.0 => /usr/local/lib/libecasoundc.so.0
bash-2.04$ ls -l /usr/local/lib/libec*
-rw-r--r-- 1 root wheel 4202212 Dec 20 01:49 /usr/local/lib/libecasound.a
-rwxr-xr-x 1 root wheel 730 Dec 20 01:49 /usr/local/lib/libecasound.la
lrwxr-xr-x 1 root wheel 16 Dec 20 01:49 /usr/local/lib/libecasound.so -> libecasound.so.7
-rwxr-xr-x 1 root wheel 2072833 Dec 20 01:49 /usr/local/lib/libecasound.so.7
-rw-r--r-- 1 root wheel 12156 Dec 20 01:49 /usr/local/lib/libecasoundc.a
-rwxr-xr-x 1 root wheel 748 Dec 20 01:49 /usr/local/lib/libecasoundc.la
lrwxr-xr-x 1 root wheel 17 Dec 20 01:49 /usr/local/lib/libecasoundc.so -> libecasoundc.so.0
-rwxr-xr-x 1 root wheel 15134 Dec 20 01:49 /usr/local/lib/libecasoundc.so.0
bash-2.04$

And the worse:

bash-2.04$ cat > conftest.c
int main() {
main()
; return 0; }
bash-2.04$ gcc -L /usr/local/lib -g -o conftest -lecasound -lkvutils conftest.c
/usr/local/lib/libecasound.so: warning: tmpnam() possibly used unsafely; consider using mkstemp()
/usr/local/lib/libecasound.so: undefined reference to `pthread_cond_signal'
[...]
/usr/local/lib/libecasound.so: undefined reference to `pthread_cond_timedwait'
bash-2.04$

Ok, then let's go with the pthreads:

bash-2.04$ gcc -L /usr/local/lib -pthread -D_THREAD_SAFE -g -o conftest -lecasound -lkvutils conftest.c
/usr/local/lib/libecasound.so: warning: tmpnam() possibly used unsafely; consider using mkstemp()
/usr/lib/libc.so.4: WARNING! setkey(3) not present in the system!
/usr/lib/libc.so.4: warning: this program uses gets(), which is unsafe.
/usr/lib/libc.so.4: warning: mktemp() possibly used unsafely; consider using mkstemp()
/usr/lib/libc.so.4: WARNING! des_setkey(3) not present in the system!
/usr/lib/libc.so.4: WARNING! encrypt(3) not present in the system!
/usr/lib/libc.so.4: warning: this program uses f_prealloc(), which is stupid.
/usr/lib/libc.so.4: WARNING! des_cipher(3) not present in the system!
/usr/lib/libc.so.4: warning: tempnam() possibly used unsafely; consider using mkstemp()
bash-2.04$ ls -l conftest
-rwxr-xr-x 1 anarcat wheel 34746 Dec 20 20:12 conftest
bash-2.04$

So it works out. WHY? I really don't get this one. And still those
weird messages.

Anyways, I figured that I could configure this using:

bash-2.04$ LDFLAGS="-pthread -L/usr/local/lib" ./configure --prefix=/u/an_temp --with-qt-includes=/usr/X11R6/include/qt2 --with-qt-libraries=/usr/X11R6/lib

and it "works", with the exception of the following warnings:

checking for QT 2.x... libraries /usr/X11R6/lib, headers /usr/X11R6/include/qt2
checking for moc... (cached) /usr/bin/moc
./configure: /COPYRIGHT: permission denied
checking for libecasound interface version 7... not present.
configure: warning: ** Compatible interface version of libecasound not found. Will still try compiling... **
checking for libqtecasound interface version 1... qtecasound-config: not found
qtecasound-config: not found
not present.
configure: warning: ** Compatible interface version of libqtecasound not found. Will still try compiling... **

Ok... Can't find ecasound. Wait, that's original. :)

config.log tells me it can't find ecasound header
<ecasound/eca-version.h> ("AAAAAAAAAAARGH"). It's there:

bash-2.04$ ls -l /usr/local/include/ecasound/eca-version.h
-rw-r--r-- 1 root wheel 927 Dec 20 01:49 /usr/local/include/ecasound/eca-version.h
bash-2.04$

I tried to configure this with:

bash-2.04$ CFLAGS="-I/usr/local/include/" CXXFLAGS="-I/usr/local/include" LDFLAGS="-pthread -L/usr/local/lib" ./configure --prefix=/u/an_temp --with-qt-includes=/usr/X11R6/include/qt2 --with-qt-libraries=/usr/X11R6/lib

It seems that CXXFLAGS don't get passed along (as CFLAGS and LDFLAGS
are). Weird, I tell you. :) So compiling in c++ flops. In C, it works
fine though. :)

The other thing is that I just realized I need qtecasound for ecawave!
(wow.)

So I switch to qtecasound. I get about the same errors.. Doing:

LDFLAGS="-pthread -L/usr/local/lib" ./configure --prefix=/u/an_temp
--with-qt-includes=/usr/X11R6/include/qt2
--with-qt-libraries=/usr/X11R6/lib

works fine (with the exception of the classical:
checking for libecasound interface version 7... not present.
configure: warning: ** Compatible interface version of libecasound not found. Will still try compiling... **
)

I also noticed the following:

Ecasound library setup:
Linker flags: -L/usr/local/lib -lecasound -lkvutils
Includes: -I/usr/local/include/ecasound

But this is wrong! Includes are in /usr/local/include, period. I mean,
anyways, you do a

#include <ecasound/whatever.h>

and not only

#include <whatever.h>

...

Anyways, I don't have much time to work on this...

Oh, and BTW, I forgot to mention this in earlier mails but:

bash-2.04$ find . -exec grep -Hn "gets *(" {} \;
./readline-4.0/tilde.c:377: if (!gets (line))
bash-2.0$4

so that's where to gets could be lurking. However, I configured
ecasound with --enable-sys-readline, which does not use gets (I
checked..).

This is mad.

I'm tired, I leave this in your holy hands. :)

A.

--
To unsubscribe send message 'unsubscribe' in the body of the
message to <ecasound-list-request@wakkanet.fi>.


New Message Reply Date view Thread view Subject view Author view Other groups

This archive was generated by hypermail 2b28 : Thu Dec 21 2000 - 03:59:37 EET