Compiling asterisk 1.4.1 on x86 with Sun Studio 11

Roadblock no. 1

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
make[2]: *** [menuselect.o] Error 2
make[2]: Leaving directory /export/home/chris/asterisk-1.4.1/menuselect' make[1]: *** [all] Error 2 make[1]: Leaving directory/export/home/chris/asterisk-1.4.1/menuselect’
make: *** [menuselect/menuselect] Error 2
:frowning:

I dont think the Sun Studio compiler suite are supported by Asterisk :smile: You will need to use gcc.

Sun Studio 12 has gcc extension support to an extent…

gcc + gnu ld does not work…I tried to compile asterisk on nexenta and failure of that led me to attempt Sun Studio.