savonet / ocaml-taglib

OCaml bindings to taglib.
http://liquidsoap.info/
Other
10 stars 1 forks source link

Taglib.File.set_properties fails with "Not implemented with taglib < 1.8." #3

Closed ul closed 7 years ago

ul commented 7 years ago

Though I have taglib 1.11.1:

> brew info taglib
taglib: stable 1.11.1 (bottled), HEAD
ul commented 7 years ago

Running ./configure by hands give this in log:

configure:5936: checking for class TagLib::PropertyMap in tag library
configure:5949: g++ -o conftest  -fno-common  -fno-common -I .. -I/usr/local/Cellar/taglib/1.11.1/include/taglib  -L/usr/local/Cellar/taglib/1.11.1/lib -ltag conftest.cpp  -ltag stdc++ >&5
clang: error: no such file or directory: 'stdc++'
configure:5949: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "ocaml-taglib"
| #define PACKAGE_TARNAME "ocaml-taglib"
| #define PACKAGE_VERSION "0.3.2"
| #define PACKAGE_STRING "ocaml-taglib 0.3.2"
| #define PACKAGE_BUGREPORT "savonet-users@lists.sourceforge.net"
| #define PACKAGE_URL ""
| /* end confdefs.h.  */
| #include <tpropertymap.h>
| int
| main ()
| {
| TagLib::PropertyMap *x = NULL
|   ;
|   return 0;
| }
configure:5957: result: not found
ul commented 7 years ago

I guess it's all happening because of clang being invoked instead of gcc. I'll try to use gcc and then report back.

ul commented 7 years ago

It compiles properly with original gcc, but it's very troublesome to use original gcc overall in macOS Sierra. Is it possible to fix config to support proper feature detection with macOS's clang pretending to be gcc?

toots commented 7 years ago

On my sierra macOS, I have:

% which gcc
/usr/bin/gcc
% gcc -help 
OVERVIEW: clang LLVM compiler

USAGE: clang [options] <inputs>
(...)

Compilation seems to be working fine.. Have you installed the X Code Comand Line Tools: http://railsapps.github.io/xcode-command-line-tools.html ?

ul commented 7 years ago

Yep, I have the same configuration and build goes fine, but every HAVE_* feature is disabled during ./configure, because that clang-y gcc gives errors described in the second message.

ul commented 7 years ago

Honestly, I think we can just remove those checks at all. ocaml-taglib is stated to support taglib 1.8 and above, so if it's okay to just not build for older versions.

toots commented 7 years ago

Good point, I'll do that.

toots commented 7 years ago

Actually, I think I'll just revert some changes that were done to please debian packagers, should fix it.

toots commented 7 years ago

Alright, sorry I spoke too soon. I still think that something is fishy in your configuration.

Would you mind posting the full configure log? Thanks!

ul commented 7 years ago

Sure! Here it is: https://gist.github.com/ul/f682bb8ae4f7d1ef448df71a83a87cd5

toots commented 7 years ago

Can you try again with the latest code? Thanks!

ul commented 7 years ago

Works like a charm, thank you! Can't wait for the opam package update =)

toots commented 7 years ago

Sweet!