Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411523 Posts in 69377 Topics- by 58431 Members - Latest Member: Bohdan_Zoshchenko

April 28, 2024, 12:54:13 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsDeveloperTechnical (Moderator: ThemsAllTook)libvorbis + Mac OS X install problem
Pages: [1]
Print
Author Topic: libvorbis + Mac OS X install problem  (Read 2094 times)
technogothica
Level 1
*



View Profile WWW
« on: September 28, 2011, 11:37:16 PM »

Hi guys,

I'm trying to build and install libogg and libvorbis from the tar.gz source packages on Mac OS X 10.7.1

libogg-1.3.0.tar.gz
libvorbis-1.3.2.tar.gz


First up I install libogg:

Code:
./configure
make
sudo make install

All works fine. Files are installed in /usr/local/include, /usr/local/lib, etc. as expected.

Now when I run configure on libvorbis, I get the following:

Code:
checking for Ogg... no
*** Could not run Ogg test program, checking why...
*** The test program failed to compile or link. See the file config.log for the
*** exact error that occurred. This usually means Ogg was incorrectly installed
*** or that you have moved Ogg since it was installed.
configure: error: must have Ogg installed!

I wrote and compiled my own C program to test that Ogg is installed properly, and everything worked. So I'm pretty sure Ogg is installed correctly.

Inspection of the config.log file reveals the following error:

Code:
configure:12668: gcc -o conftest -DDARWIN -fno-common -force_cpusubtype_ALL -Wall -g -04 -ffast-math -fsigned-char -DUSE_MEMORY_H conftest.c -logg >&5
ld: in /var/folders/.../ccZoNQ0N.o, could not parse object file /var/folders/.../ccZoNQ0N.o: Malformed metadata record for architecture x86_64
collect2: ld returned 1 exit status

The problem appears to be a linker error. Since my own test worked okay, the problem must be with the configure script itself?

Thanks in advance.
Logged

Glaiel-Gamer
Guest
« Reply #1 on: September 28, 2011, 11:52:11 PM »

stb vorbis
1 .c file, 1 .h file, no dependencies
Logged
ThemsAllTook
Administrator
Level 10
******



View Profile WWW
« Reply #2 on: September 29, 2011, 06:07:50 AM »

You'll need to pass --with-ogg-libraries="/path/to/directory/containing/libogg.a/" --with-ogg-includes="/path/to/directory/containing/ogg/include/directory/" to the configure script.
Logged

Average Software
Level 10
*****

Fleeing all W'rkncacnter


View Profile WWW
« Reply #3 on: September 29, 2011, 06:43:08 AM »

When I did this, I took the sources and made proper frameworks out of them.  Saved me a lot of hassle in the long run.  If you know how to build frameworks, you might consider doing that.
Logged



What would John Carmack do?
technogothica
Level 1
*



View Profile WWW
« Reply #4 on: September 29, 2011, 06:45:15 AM »

I figured it out!

The problem was that configure script for libogg was detecting the build target as x86_64 (which is correct), but the configure script for libvorbis was detecting i386. Configure was failing because libogg.a was built for a different architecture than libvorbis was expecting.

The solution was to force a build target:

Code:
./configure --build=x86_64

Thanks to everyone who responded Gentleman
Logged

Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic