Opened 15 years ago

Last modified 13 years ago

#1477 new defect

FTBFS libavcodec: Error: unbalanced parenthesis in operand 1.

Reported by: ptecza@… Owned by: reimar
Priority: normal Component: ve
Version: HEAD Severity: normal
Keywords: Cc: bobl@…, nikke@…
Blocked By: Blocking:
Reproduced by developer: no Analyzed by developer: no

Description

I can't compile the latest SVN trunk revision (r29324) under my OpenSolaris Indiana box. It fails with the following error message:

$ ./configure --prefix=/opt/mplayer
$ gmake
[...]
./version.sh cc -dumpversion
gmake -C libavcodec
gmake[1]: Entering directory `/path/to/mplayer/libavcodec'
cc -DHAVE_AV_CONFIG_H -I.. -I.. -Wundef -Wdisabled-optimization -Wdeclaration-after-statement -std=gnu99 -Wall -Wno-switch -Wpointer-arith -Wredundant-decls -O4 -march=pentium-m -mtune=pentium-m -pipe -ffast-math -fomit-frame-pointer -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -Ilibdvdread4 -I. -I/usr/X11/include -I/usr/include/SDL -D_REENTRANT -I/usr/include/freetype2 -c -o x86/mlpdsp.o x86/mlpdsp.c
{standard input}: Assembler messages:
{standard input}:92: Error: unbalanced parenthesis in operand 1.
{standard input}:97: Error: unbalanced parenthesis in operand 1.
{standard input}:102: Error: unbalanced parenthesis in operand 1.
{standard input}:107: Error: unbalanced parenthesis in operand 1.
{standard input}:124: Error: unbalanced parenthesis in operand 2.
gmake[1]: * [x86/mlpdsp.o] Error 1
gmake[1]: Leaving directory `/path/to/mplayer/libavcodec'
gmake:
* [libavcodec/libavcodec.a] Error 2

Here are more details about my system:

$ uname -a
SunOS opensolaris 5.11 snv_111a i86pc i386 i86pc Solaris

$ ls -l /lib/libc[.-]*
lrwxrwxrwx 1 root root 9 2009-04-27 23:10 /lib/libc.so -> libc.so.1
-rwxr-xr-x 1 root bin 1704024 2009-05-03 22:53 /lib/libc.so.1

$ cc -v
Reading specs from /usr/sfw/lib/gcc/i386-pc-solaris2.11/3.4.3/specs
Configured with: /builds2/sfwnv-111a/usr/src/cmd/gcc/gcc-3.4.3/configure --prefix=/usr/sfw --with-as=/usr/sfw/bin/gas --with-gnu-as --with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++,f77,objc --enable-shared
Thread model: posix
gcc version 3.4.3 (csl-sol210-3_4-20050802)

$ ld -v
GNU ld version 2.15

$ as -v
GNU assembler version 2.15 (i386-pc-solaris2.11) using BFD version 2.15

Should I give you another information? For example my config.h and config.mak files?

Attachments (1)

mplayer-libavcodec-solparens.diff (721 bytes ) - added by nikke@… 15 years ago.
Workaround for the solaris gas paren matching bug

Download all attachments as: .zip

Change History (7)

comment:1 by bobl@…, 15 years ago

Cc: bobl@… added

From Sun CC
"x86/mlpdsp.c", line 44: address of a void object cannot be taken
"x86/mlpdsp.c", line 44: address of a void object cannot be taken
"x86/mlpdsp.c", line 45: address of a void object cannot be taken
"x86/mlpdsp.c", line 45: address of a void object cannot be taken
"x86/mlpdsp.c", line 46: address of a void object cannot be taken
"x86/mlpdsp.c", line 46: address of a void object cannot be taken
"x86/mlpdsp.c", line 47: address of a void object cannot be taken
"x86/mlpdsp.c", line 47: address of a void object cannot be taken
"x86/mlpdsp.c", line 48: address of a void object cannot be taken
"x86/mlpdsp.c", line 49: address of a void object cannot be taken
"x86/mlpdsp.c", line 49: address of a void object cannot be taken
"x86/mlpdsp.c", line 50: address of a void object cannot be taken
"x86/mlpdsp.c", line 50: address of a void object cannot be taken
"x86/mlpdsp.c", line 51: address of a void object cannot be taken
"x86/mlpdsp.c", line 169: operand of the constraint "m" must be lvalue

comment:2 by bobl@…, 15 years ago

Gas doesn't like the following syntax that results from the MACRO IIRMUL

ff_mlp_iirorder_3:

*

mov 0x08+4*(8 + (40 * (192000 / 48000)))(%ebp), %eax

*
imull 0x08+4* 8(%edi)
add %eax , %esi
adc %edx , %ecx


by nikke@…, 15 years ago

Workaround for the solaris gas paren matching bug

comment:3 by nikke@…, 15 years ago

The bug seems to be that the GNU assembler available on Solaris (in my case
OpenSolaris 2009.06) doesn't seem to like nested parentheses.

This patch shows how to work around this by simply evaluating the expression
in the header file. Ugly but effective.

comment:4 by nikke@…, 15 years ago

Cc: nikke@… added

comment:5 by ptecza@…, 15 years ago

(In reply to comment #3)

Created an attachment (id=559) [details]
Workaround for the solaris gas paren matching bug

Niklas, thanks a lot for the patch! Now I can compile and run MPlayer
under OpenSolaris 2009.06 :D

comment:6 by compn, 13 years ago

Owner: changed from r_togni@… to reimar
Note: See TracTickets for help on using tickets.