Building MySQL 5.1.28 on Opensolaris using Sun Studio compilers

Want to use Dtrace or ZFS but are unfamiliar with building MySQL on Solaris? Dont panic, its never been easier. Here are the steps that worked for me.
  1. Install OpenSolaris using the latest development ISO file
  2. Install developer tools
    pfexec pkg install ss-dev
  3. Download 5.1.28rc source
  4. Build it
    export CC=/opt/SunStudioExpress/bin/cc
    export CXX=/opt/SunStudioExpress/bin/CC
    export CFLAGS="-xO3" #Your fav compiler flags go here 
    export CXXFLAGS="-xO3"
    
    ./configure --with-plugins=innobase,myisam --with-mysqld-libs=-lmtmalloc
    gmake 
    

Yes, it is that simple. Of course you could just download the binaries and use them too; they work just fine.

Comments:

Thanks a whole lot.

I wish other developers could also share their experience of how to build their packages. This is what an open source system is all about. Sun Studio rules!

Posted by W. Wayne Liauh on October 13, 2008 at 11:29 AM PDT #

Even easier, the OpenSolaris Web Stack team has preview MySQL 5.1 packages available for testing via IPS from the Web Stack project repository at:

http://pkg.opensolaris.org/webstack/

These are preview builds of the MySQL 5.1 which will go into OpenSolaris in the near future, so it's a good way to get a head start testing/playing with them.

For more info on Web Stack check out
http://opensolaris.org/os/project/webstack/

Posted by Jyri Virkki on October 13, 2008 at 12:37 PM PDT #

Post a Comment:
Comments are closed for this entry.
About

realneel

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today