Trouble Using Compiling with TagLib
Bhatnagar, Arvin
arvin.bhatnagar at verizon.com
Fri Sep 30 13:52:40 UTC 2011
Hi All,
I'm sure I must be doing something very very stupid being unable to compile my project with TagLib.
Environment:
Mac OS X 10.6.8 (64-bit)
Xcode 4.2 Build 4C104
TagLib 1.7
* Download TagLib 1.7
* Unpack TagLib 1.7
* Run the following cmake command:
cmake -DCMAKE_BUILD_TYPE=Release -DINSTALL_LIBS=ON -DBUILD_SHARED_LIBS=ON -DCMAKE_OSX_SYSROOT=/Developer/SDKs/MacOSX10.6.sdk/ -DCMAKE_OSX_DEPLOYMENT_TARGET=10.6 -DCMAKE_OSX_ARCHITECTURES="i386;x86_64" -DENABLE_STATIC=ON -DCMAKE_INSTALL_PREFIX="/usr/local"
* Run "make"
* Run "sudo make install"
Xcode Project Settings:
* Architectures – Standard 32/64-bit Intel
* Base SDK – Mack OS X 10.6
* Valid Architectures – i386 x86_64
* Compiler – Apple LLVM compiler 3.0
* Mac OS X Deployment Target – Mac OS X 10.6
* Header Search Paths - /usr/local/include/**
* Library Search Paths - /usr/local/lib/**
Xcode Code:
* I have .h and .mm files
* The .mm file has these #import's
#import <taglib/tag.h>
#import <taglib/tag_c.h>
#import <taglib/taglib.h>
* My function is just this:
+ (void) audioMetaData:(NSURL *)audioURL {
if ( audioURL && [audioURL isFileURL] ) {
TagLib_File *file = nil;
TagLib_Tag *tag = nil;
taglib_set_strings_unicode(YES);
file = taglib_file_new([[audioURL path] fileSystemRepresentation]);
tag = taglib_file_tag(file);
taglib_tag_free_strings();
taglib_file_free(file);
}
}
* When I compile this is the error received:
Undefined symbols for architecture x86_64:
"_taglib_set_strings_unicode", referenced from:
+[AudioMetaData audioMetaData:] in AudioMetaData.o
"_taglib_file_new", referenced from:
+[AudioMetaData audioMetaData:] in AudioMetaData.o
"_taglib_file_tag", referenced from:
+[AudioMetaData audioMetaData:] in AudioMetaData.o
"_taglib_tag_free_strings", referenced from:
+[AudioMetaData audioMetaData:] in AudioMetaData.o
"_taglib_file_free", referenced from:
+[AudioMetaData audioMetaData:] in AudioMetaData.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Command /Developer/usr/bin/clang++ failed with exit code 1
I spent all day on this yesterday and thought I would ask the experts out on this list for any advice. So please if anyone can shed some light on this for me, I would be very grateful!
Thanks,
Arvin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/taglib-devel/attachments/20110930/b819504f/attachment.html>
More information about the taglib-devel
mailing list