Works for me on Solaris 11 x86.
Did simple ./configure with cc/CC pointing out to suncc/sunCC and then gmake:
...
suncc-o menuselect.o -g -c -D_GNU_SOURCE menuselect.c
"menuselect.c", line 472: warning: implicit function declaration: strsep
"menuselect.c", line 747: warning: improper pointer/integer combination: op "="
"menuselect.c", line 748: warning: improper pointer/integer combination: op "="
"menuselect.c", line 809: warning: improper pointer/integer combination: op "="
"menuselect.c", line 822: warning: improper pointer/integer combination: op "="
"menuselect.c", line 935: warning: implicit function declaration: ast_strdupa
"menuselect.c", line 935: warning: improper pointer/integer combination: op "="
"menuselect.c", line 935: warning: improper pointer/integer combination: op "="
"menuselect.c", line 937: warning: improper pointer/integer combination: op "="
"menuselect.c", line 945: warning: improper pointer/integer combination: op "="
"menuselect.c", line 945: warning: improper pointer/integer combination: op "="
"menuselect.c", line 947: warning: improper pointer/integer combination: op "="
It fails later on (misconfigured - absent include file) menuselect/strcompat.c
regards,
__Fedor.
CC=/home/chris/SUNWspro/bin/cc CXX=/home/chris/SUNWspro/bin/CC ./configure --prefix=/opt/asterisk
-bash-3.00$ gmake
gmake[1]: Entering directory `/sfe/sources/chris/asterisk-1.4.2/menuselect'
gmake[2]: Entering directory `/sfe/sources/chris/asterisk-1.4.2/menuselect'
cc-o menuselect.o -g -c -D_GNU_SOURCE menuselect.c
"menuselect.c", line 165: syntax error before or at: {
"menuselect.c", line 165: undefined symbol: cur
"menuselect.c", line 165: non-unique member requires struct/union pointer: list
"menuselect.c", line 165: left operand of "->" must be pointer to struct/union
"menuselect.c", line 165: warning: assignment type mismatch:
pointer to struct depend {pointer to const char name, pointer to struct member {..} member, struct {..} list} "=" pointer to struct dep_file {array[32] of char name, int met, struct {..} list}
"menuselect.c", line 165: non-unique member requires struct/union pointer: list
"menuselect.c", line 165: left operand of "->" must be pointer to struct/union
"menuselect.c", line 165: warning: improper pointer/integer combination: op "=="
"menuselect.c", line 165: undefined symbol: cur
"menuselect.c", line 165: cannot recover from previous errors
cc: acomp failed for menuselect.c
gmake[2]: *** [menuselect.o] Error 2
gmake[2]: Leaving directory `/sfe/sources/chris/asterisk-1.4.2/menuselect'
gmake[1]: *** [all] Error 2
gmake[1]: Leaving directory `/sfe/sources/chris/asterisk-1.4.2/menuselect'
gmake: *** [menuselect/menuselect] Error 2
I had to remove all the -Wall options from the menuselect Makefile. Are you saying you did not?
> CC=/home/chris/SUNWspro/bin/cc
> cc -o menuselect.o -g -c -D_GNU_SOURCE menuselect.c
The fact that it uses cc and not the whole path as specified in CC looks suspicious to me. Are you sure it is using the right compiler? Try putting /home/chris/SUNWspro/bin at the beginning of your PATH.
I do have /home/chris/SUNWspro/bin at the beginning of my path.
Last login: Thu Apr 19 14:50:57 2007 from 192.168.168.1
Sun Microsystems Inc.SunOS 5.11snv_59 October 2007
-bash-3.00$ echo $PATH
/home/chris/SUNWspro/bin:/usr/perl5/bin:/usr/ccs/bin:/usr/bin:/opt/sfw/bin:/usr /ucb
-bash-3.00$
cc -V
-bash-3.00$ /home/chris/SUNWspro/bin/cc -v
usage: cc [ options] files. Use 'cc -flags' for details
-bash-3.00$ /home/chris/SUNWspro/bin/cc -V
cc: Sun C 5.8 Patch 121016-05 2007/01/10
usage: cc [ options] files. Use 'cc -flags' for details
-bash-3.00$
I do have Sun Studio 11 in /opt/SUNspro FYI.