Wednesday, May 14, 2008

Open SSL installion issue on Solaris

I was installing openssl-0.9.7 on solaris when I got following error:
cc1: error: invalid option `arch=ultrasparc'

This was very strange, I googled but could not find the answer. Then I checked the operating system details, and here are the details:
uname -m --> sun4u
uname -r --> 5.9
uname -s --> SunOS
uname -v --> Generic_118558-28
gcc -v --> 3.4.6
I was using default ./config for installtion, which was selecting solaris-sparcv9-gcc as os/compiler flag. It assumed since i am using gcc version > 3.0 it would recognize -march=ultrasparc option. But since my compiler didn't understand that, I used following command.
bash# ./Configure solaris-sparcv9-gcc27
This forces it the config to not use the -march... option. So the above error disappeared, but resulted in one more error: 'ar command not found'
This time solution was easy, I just added /usr/ccs/bin to the path and it worked.

No comments: