Installing NS-2 2.33 or 2.34 on Mac OS X 10.6 (aka Snow Leopard)

8 09 2011

Apply the following modifications to the file ns-allinone-2.34/install: (add what’s in red and in green*)

* the lines in green are, possibly, only necessary to Mac OS X 10.6 (aka Snow Leopard). With Mac OS X 10.5 (aka Leopard), the red lines should be enough.

Modification 1

echo "============================================================"
echo "* Build OTcl-$OTCLVER"
echo "============================================================"
cd ./otcl-$OTCLVER
blame='Please check http://www.isi.edu/nsnam/ns/ns-problems.html
for common problems and bug fixes.'
if  [ "${test_cygwin}" = "true" ]; then
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include || die "otcl-$OTCLVER configuration failed! Exiting ...";
else
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include CFLAGS="-framework CoreFoundation" || die "otcl-$OTCLVER configuration failed! Exiting ...";
fi
if make
then
     echo "otcl-$OTCLVER has been installed successfully."
else
     echo "otcl-$OTCLVER make failed! Exiting ..."
     echo "See http://www.isi.edu/nsnam/ns/ns-problems.html for problems"
     exit
fi
cd ..

Modification 2

echo "============================================================"
echo "* Build Tclcl-$TCLCLVER"
echo "============================================================"
cd ./tclcl-$TCLCLVER
if  [ "${test_cygwin}" = "true" ]; then
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include || die "tclcl-$TCLCLVER configuration failed! Exiting ...";
else
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include --with-otcl=../otcl-$OTCLVER || die "tclcl-$TCLCLVER configuration failed! Exiting ..."
fi
if make
then
     echo "tclcl-$TCLCLVER has been installed successfully."
else
     echo "tclcl-$TCLCLVER make failed! Exiting ..."
     echo "See http://www.isi.edu/nsnam/ns/ns-problems.html for problems"
     exit
fi    
cd ../

Modification 3

echo "============================================================"
echo "* Build ns-$NSVER"
echo "============================================================"
cd ./ns-$NSVER
if [ -f Makefile ] ; then
     make distclean
fi
if  [ "${test_cygwin}" = "true" ]; then
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include || die "Ns configuration failed! Exiting ...";
else
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include LIBS="-framework CoreFoundation" --with-otcl=../otcl-$OTCLVER --with-tclcl=../tclcl-$TCLCLVER || die "Ns configuration failed! Exiting ...";
fi
if make
then
     echo " Ns has been installed successfully."
else
     echo "Ns make failed!"
     echo "See http://www.isi.edu/nsnam/ns/ns-problems.html for problems"
     exit
fi
cd ../

Modification 4

echo "============================================================"
echo "* Build nam-$NAMVER"
echo "============================================================"
ln -s otcl-$OTCLVER otcl
ln -s tclcl-$TCLCLVER tclcl
cd ./nam-$NAMVER
# XXX temporary OS X hack
if  [ "${test_darwin}" = "true" ]; then
ln -s /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation libcorefoundation.dylib
fi
if  [ "${test_cygwin}" = "true" ]; then
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include --with-tclcl=$CUR_PATH/tclcl-$TCLCLVER  || die "Nam configuration failed! Exiting ...";
else
        ./configure --x-libraries=/usr/X11R6/lib --x-includes=/usr/X11R6/include V_LIBS="-framework CoreFoundation" --with-otcl=../otcl-$OTCLVER --with-tclcl=../tclcl-$TCLCLVER || die "Nam configuration failed! Exiting ...";
fi
............
cd ../

After applying those modifications, use Terminal app to go to the ns-allinone-2.3x directory and enter  ./install.

Those installation procedures were tested with Max OS X 10.6, but they should work just fine with 10.5.

STILL HAVING PROBLEMS DURING INSTALLATION?

1. If, even after applying the above modifications, your installation fails, proceed as follows:

Install first Xcode development tools. They come with Mac OS X 10.6 CD as an optional installation. After doing that, proceed as explained above.

2. Still failing? Check the following instruction:

In the configure files inside nam, ns, otcl and tclcl directories, look for xlibdirs and xincdirs and check if the following lines, respectively, can be found:

/Developer/SDKs/MacOSX10.4u.sdk/usr/X11R6/lib \

and

/Developer/SDKs/MacOSX10.4u.sdk/usr/X11R6/include \

In NS-2 version 2.34, those lines are present. You should carefully  look for them when using other versions.

 

Anything to say about it? Drop a line in the comments!

 





Mandando notícias

26 08 2010

Faz muito, mas muito tempo mesmo que eu não posto nada aqui.

Mac, Android, Nagios, Centreon, Linux… Assunto é o que não falta, o que falta é tempo.

Estou com uma série de tutoriais, dicas e comentários sobre uma tonelada de coisas. Aos poucos pretendo postá-las, só não sei se nesse blog ou se em outro voltado a assuntos mais técnicos.

Bem, enquanto não encontro tempo pra postar, agradeço aos milhares (sim! milhares!) de visitas que o blog recebe por mês.

Espero que mesmo desatualizado, esse blog ajude muitos de vocês.





Covertendo WMA em MP3 no Mac OS. De graça ;)

15 02 2010

Hoje em dia, a regra é arquivo de áudio em MP3. Mesmo assim, vez ou outra você pode encontrar um em WMA.

Executar e lidar com esses arquivos no Windows não é nenhum problema, já que ele é um formato proprietário da Microsoft (Windows Media Audio – WMA). Já no Mac a história é diferente. Você pode até usar plugins capazes de executar os arquivos, mas nem espere adicioná-los ao iTunes.

Existem diversos conversores de WMA para MP3 para o Mac oS, mas ou eles são pagos e/ou não funcionavam como prometido.

Uma alternativa é um programa chamado All2MP3. Ele é grátis, simples E funciona.

Janela do All2MP3

Janela do All2MP3

Tudo que você tem que fazer é arrastar para a janela do programa os arquivos de áudio que você quer converter, escolher a qualidade dos arquivos a serem gerados, clicar em ‘Convert’ e pronto!

Como visto na imagem, o programa converte diversos formatos de áudio para MP3, desde OGG até WMA.

Biaxe aqui o All2MP3.

P.S.: Não testei o programa quanto ao uso com arquivos WMA protegidos. Se você testar, deixe um comentário com a sua experiência.








Follow

Get every new post delivered to your Inbox.