Re: Configure error, Ogg not found on Mac OS X

Unga <[email protected]> Mon, 21 Apr 2014 03:19:16 -0700 (PDT)
Newsgroups gmane.comp.multimedia.ogg.vorbis.general
Message-ID <[email protected]>

> On Monday, April 21, 2014 3:00 PM, Joshua Root <[email protected]> wro=
te:
> > On 2014-4-21 17:38 , Unga wrote:
>> =

>>  I have narrow down the problem with the following test program:
>> =

>>  #include <stdio.h>
>> =

>>  char oggpack_writealign ();
>> =

>>  int
>>  main ()
>>  {
>> =A0 return oggpack_writealign ();
>> =A0 return 0;
>>  }
>> =

>>  LD_LIBRARY_PATH=3D'/usr/lib' clang oggpack.c -DDARWIN -fno-common =

> -force_cpusubtype_ALL -Wall -g -O3 -ffast-math -fsigned-char =

> -Wdeclaration-after-statement=A0 -DUSE_MEMORY_H -I/usr/include -logg -lpt=
hread -o =

> oggpack
> =

> LD_LIBRARY_PATH is hardly used on OS X (only by dlopen() AFAIK) and
> there isn't an exact equivalent to the function it has on Linux. You
> probably meant LIBRARY_PATH if you wanted (roughly) the equivalent of -L?
> =

>>  ld: library not found for -logg
>>  clang: error: linker command failed with exit code 1 (use -v to see =

> invocation)
> =

> Works for me (when I create a libogg.dylib link in /usr/lib). What clang
> are you using? (-v would have shown this.)
> =

> =

> - Josh
> =


ok, problem solved. It's, users should not install to /usr in Mac OS X!!!=
=A0

I removed the libogg from /usr and reinstalled to /usr/local, and compiled =
my test program, it just worked. Also the libvorbis.

Btw, the clang version:
Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn)

Thank you, Josh.

Best regards
Unga