Meet Mr. DTrace – Part 3
Web April 26th, 2007
Thanks to Ben Klang’s comments, I eventually make the SunStudio 11 works on NexentaOS!
Stick to the bleeding-edge
I migrated to NexentaOS Alpha-7 test2, since the SUNWhea is maintained in the unstable brach. Edited the /etc/apt/source.list to use unstable instead of testing, then upgraded the SUNWhea package, at the end “emerge” the SPROcc from the OpenSolaris DVD.
Test drive of DTrace probes provider
Copy the simple.c, myserv.d from Ticket #405, build it using SunStudio C Compiler:
dtrace -G -32 -s myserv.d simple.o
cc -o simple myserv.o simple.o
Prepare the test.d like this:
Launch the simple with root privilege, execute the test.d with root privilege as well. The terminal would print out the value of counter i. Bravo!
Building the Mozilla Firefox
To build Mozilla Firefox, we need install the C++ compiler environment:
SPROscl Sun Studio 11 Standard Class Library for C++
SPROsbld Sun Studio 11 Linker Stab Library
To simplify the installation, –force option is added to emerge.py to install packages regardless the dependencies.
We also need to install libgtk2.0-dev and libidl-dev to meet the dependencies required by Firefox.
Fetch the source code using apt-get source firefox, edit the $HOME/.mozconfig,
ac_add_options –prefix=/opt/firefox
ac_add_options –enable-application=browser
ac_add_options –enable-optimize=”-xO2″
then invoke configure, make:
cd config ; make
cd ../js; make
CC reported an error at the linking time: /usr/ccs/bin/ar is not found. It seems that there is still some package missing, not quite sure it is binutils, I would ask for help from #gnusol tomorrow.







Leave a Comment