Musepack Forums  

Go Back   Musepack Forums > Main > MPC for UNIX

Reply
 
Thread Tools Search this Thread Display Modes
Old 27 April 2005, 06:21 pm   #1
Exekutor
Member
 
Join Date: Apr 2005
Posts: 1
Default Problem Compiling BMP Plugin on Ubuntu

I've compiled and installed libmusepack-1.1.1 without any errors.

The configuration process for bmp-musepack-1.1.2 was ok, but when compilig, gives the error:

Code:
libmpc.cpp:37: error: parse error before `*' token
libmpc.cpp:61: error: parse error before `*' token
libmpc.cpp:70: error: type specifier omitted for parameter `BOOL'
libmpc.cpp:70: error: parse error before `)' token
libmpc.cpp: In function `void setup_reader(...)':
libmpc.cpp:72: error: `data' undeclared (first use this function)
libmpc.cpp:72: error: (Each undeclared identifier is reported only once for
   each function it appears in.)
libmpc.cpp:72: error: `input' undeclared (first use this function)
libmpc.cpp:73: error: `seekable' undeclared (first use this function)
libmpc.cpp:78: error: `reader' undeclared (first use this function)
libmpc.cpp:80: error: `seek_impl' undeclared (first use this function)
libmpc.cpp:83: error: `canseek_impl' undeclared (first use this function)
make[2]: *** [libmpc.lo] Error 1
make[2]: Leaving directory `/home/cristobal/musepack/bmp-musepack-1.1.2/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/cristobal/musepack/bmp-musepack-1.1.2/src'
make: *** [all-recursive] Error 1
Maybe the version of the pluguin (i'm using the 1.1.2) requires the same version of libmusepack (i'm using the 1.1.1), but on the download page those are available only.

Or maybe a dependency problem?.
Exekutor is offline   Reply With Quote
Old 27 April 2005, 06:43 pm   #2
Lefungus
Procrastinator
 
Lefungus's Avatar
 
Join Date: Jul 2004
Posts: 131
Default

Use the search button, someone already asked about that a few months ago.
Lefungus is offline   Reply With Quote
Old 27 April 2005, 07:11 pm   #3
Shy
Admin
 
Shy's Avatar
 
Join Date: Jul 2004
Posts: 372
Default

Due to questions like this being repeated, an entry is added to the General FAQ on the site.
Shy is offline   Reply With Quote
Old 30 April 2005, 02:20 am   #4
piman
Member
 
Join Date: Jan 2005
Location: Minneapolis, MN
Posts: 6
Default

This is not a repeat problem, as far as I can tell. Certainly the FAQ entry you mentioned does not tell people how to fix it! It is due to a change in libmusepack 1.1.1. The 'BOOL' type was changed to 'mpc_bool_t' between 1.1 and 1.1.1. This change was not documented, was API-incompatible, and happened in a minor revision. In short, it was stupid.

See, for example, https://www.sacredchao.net/quodlibet/ticket/55, where I had to fix the same bug in PyMusepack.

Please, when you change your library, document it and bump the SONAME and version number appropriately. If you don't, no one will use it, and I'll have to fork it to have it in Debian properly.
__________________
--
Joe Wreschnig
piman is offline   Reply With Quote
Old 30 April 2005, 01:48 pm   #5
Lefungus
Procrastinator
 
Lefungus's Avatar
 
Join Date: Jul 2004
Posts: 131
Default

You are talking about two things.

- Exekutor has exactly the issue described in the FAQ, meaning he forgot to specify where to install libmusepack, and so bmp-musepack can't compile properly. I don't know yet how to make bmp configure script more robust, so meanwhile, the solution is to use "configure --prefix=..." when the default path isn't appropriate.
Note that he only installed libmusepack-1.1.1, the latest version.

- The API change wasn't properly documented, and the version number should have been bumped to 1.2. Ok, this is entirely my fault, I won't repeat this error twice. Jumping at my throat with an angry report won't make it better though. For the next release, be sure I'll put up a "release candidate" before, for you or any people to check out and iron out bugs like these.
Lefungus is offline   Reply With Quote
Old 01 May 2005, 02:47 am   #6
piman
Member
 
Join Date: Jan 2005
Location: Minneapolis, MN
Posts: 6
Default

Quote:
Originally Posted by Lefungus
- Exekutor has exactly the issue described in the FAQ, meaning he forgot to specify where to install libmusepack, and so bmp-musepack can't compile properly. I don't know yet how to make bmp configure script more robust, so meanwhile, the solution is to use "configure --prefix=..." when the default path isn't appropriate.
Note that he only installed libmusepack-1.1.1, the latest version.
Sure. He installed libmusepack-1.1.1 -- with mpc_bool_t -- and tried to compile bmp-musepack 1.1.2 -- with BOOL, as the error clearly shows. This is related to the type change, nothing to do with the prefix. Anyone who downloads bmp-musepack and libmusepack from the canonical download links on the musepack.net sidebar is *not* going to be able to compile bmp-musepack, and that FAQ entry is not going to tell them how.

Quote:
Originally Posted by Lefungus
- The API change wasn't properly documented, and the version number should have been bumped to 1.2. Ok, this is entirely my fault, I won't repeat this error twice. Jumping at my throat with an angry report won't make it better though. For the next release, be sure I'll put up a "release candidate" before, for you or any people to check out and iron out bugs like these.
My report was not angry, but it was factual, and the problem is incredibly frustrating. Not bumping the version is stupid. We all do stupid things periodically, it doesn't make them less stupid. And if you don't bump the version, I do have to maintain a fork for Debian, where policy demands (rightly) I bump versions.
__________________
--
Joe Wreschnig
piman is offline   Reply With Quote
Old 01 May 2005, 11:16 am   #7
Lefungus
Procrastinator
 
Lefungus's Avatar
 
Join Date: Jul 2004
Posts: 131
Default

Blah, I was wrong for bmp too, for some reason, it was compiling fine on my comp while it shouldn't.
I'm currently fixing the whole mess, sorry for the occasionated trouble.
Lefungus is offline   Reply With Quote
Old 05 May 2005, 11:36 pm   #8
crazee_canuck
Member
 
Join Date: May 2005
Posts: 8
Default

Quote:
Originally Posted by piman
This is not a repeat problem, as far as I can tell. Certainly the FAQ entry you mentioned does not tell people how to fix it! It is due to a change in libmusepack 1.1.1. The 'BOOL' type was changed to 'mpc_bool_t' between 1.1 and 1.1.1. This change was not documented, was API-incompatible, and happened in a minor revision. In short, it was stupid.

See, for example, https://www.sacredchao.net/quodlibet/ticket/55, where I had to fix the same bug in PyMusepack.

Please, when you change your library, document it and bump the SONAME and version number appropriately. If you don't, no one will use it, and I'll have to fork it to have it in Debian properly.
Thank you, because of your post I was able to compile bmp-musepack.


To the original poster, if you haven't fixed it yet, the following patch let you compile bmp-musepack:


Code:
--- bmp-musepack-1.1.2.orig/src/libmpc.cpp
+++ bmp-musepack-1.1.2/src/libmpc.cpp
@@ -33,7 +33,7 @@
     return vfs_fread(ptr, 1, size, d->file);
 }

-BOOL
+mpc_bool_t
 seek_impl(void *data, int offset)
 {
     reader_data *d = (reader_data *) data;
@@ -57,7 +57,7 @@
     return d->size;
 }

-BOOL
+mpc_bool_t
 canseek_impl(void *data)
 {
     reader_data *d = (reader_data *) data;
@@ -67,7 +67,7 @@

 void
 setup_reader(mpc_reader * reader, reader_data * data, VFSFile * input,
-                 BOOL seekable)
+                 mpc_bool_t seekable)
 {
     data->file = input;
     data->seekable = seekable;
Such a simple fix, and I've been playing with it for the last hour thinking it was something screwed with my libraries....*sigh*

BTW:

Quote:
My report was not angry, but it was factual, and the problem is incredibly frustrating. Not bumping the version is stupid. We all do stupid things periodically, it doesn't make them less stupid. And if you don't bump the version, I do have to maintain a fork for Debian, where policy demands (rightly) I bump versions.
I don't think that is an angry report at all. For a non-coder such as myself, I needed a kick in the rear to know how to fix it...and piman helped me (and hopefully the OP) fix it.

Cheers.
crazee_canuck is offline   Reply With Quote
Old 06 May 2005, 01:22 pm   #9
Lefungus
Procrastinator
 
Lefungus's Avatar
 
Join Date: Jul 2004
Posts: 131
Default

Yes, the fix is actually quite simple, when you're aware of it
I'll post new versions for the lib, and xmms/bmp plugins today or tomorrow now.
Lefungus is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
XMMS 1.1.2 plugin on FreeBSD Olev MPC for UNIX 1 28 March 2005 05:13 pm
problem compiling xmms-musepack /usr/lib/libstdc++.so ... judas_iscariote MPC for UNIX 3 23 January 2005 01:36 am


All times are GMT. The time now is 06:27 pm.


Powered by vBulletin® Version 3.8.11 Beta 2
Copyright ©2000 - 2019, vBulletin Solutions Inc.