Windows 7 + vmware7.0 + ubuntu10.0 + NS-2.33 Installation Log

Source: Internet
Author: User
  1. Download and install VMWare, ubuntu. ISO
  2. Do the following:


    Sudo apt-Get install build-essential

    Sudo apt-Get install tcl8.4

    Sudo apt-Get install tcl8.4-Dev

    Sudo apt-Get install tk8.4

    Sudo apt-Get install tk8.4-Dev

    Sudo apt-Get install libxmu-Dev

    Using "gcc-V" to check GCC version (e.g. 4.4.5), then install g ++ with the same version

    Sudo apt-Get install g ++ 4.4.5. if not available, direclty type "G ++", without version

  3. Tar-vxzf ns-allinone-2.33.tar.gz
  4. Install the pacth, in case the error (when using NAM) like the following:
    NAM:
    [Code omitted because of length]
    : No event type or button # Or keysym
    While executing
    "Bind ListBox <mousewheel> {
    % W yview scroll [expr {-(% d/120) * 4}] Units
    }"
    Invoked from
    "If {[String equal [TK windowingsystem]" classic "]
    | [String equal [TK windowingsystem] "Aqua"]} {
    Bind ListBox <mousewheel> {
    % W yview scroll [expr {..."
     
    Solution:
    1). http://bugs.gentoo.org/show_bug.cgi? Id = 225999, download Patch
    2). Under "ns-allinone-2.33", patch-P0 <tk-8.4.18-tkBind.patch
    3). Under "ns-allinone-2.33> tk8.4.18", patch-P0 <tk-8.4.lastevent.patch
  5. 1). $ CD/home/ns-allinone-2.33/otcl-1.13

    $ Sudo gedit Configure. In

    Modify at "Linux *)":

    Shlib_ld = "LD-shared ",

    As

    Shlib_ld = "gcc-shared"

    2). $ sudo gedit configure

    Modify at "Linux *)"

    Shlib_ld = "LD-shared ",

    As

    Shlib_ld = "gcc-shared"

    3). Change ns-allinone-2.34/otcl-1.13/makefile. In

    Cc = @ CC @

    Cc = gcc-4.4 (UR current version)

    4). Enter ns-allinone-2.33
    ./Install

  6. Setup Path Environment

    Gedit ~ /. Bashrc

    At the end of the file, type the following

    (Note:/home/ns is ur own path for ns-allinone-2.33)

    # LD_LIBRARY_PATH

    Ootcl_lib =/home/ns/ns-allinone-2.33/otcl-1.13

    Ns2_lib =/home/ns/ns-allinone-2.33/lib

    X11_lib =/usr/x11r6/lib

    Export LD_LIBRARY_PATH = $ LD_LIBRARY_PATH: $ otcl_lib: $ ns2_lib: $ x11_lib

     

    # Tcl_library

    Tcl_lib =/home/ns/ns-allinone-2.33/tcl8.4.18/Library

    Usr_lib =/usr/lib

    Export tcl_library = $ tcl_lib: $ usr_lib

     

    # Path

    Xgraph =/home/ns/ns-allinone-2.33/bin:/home/ns/ns-allinone-2.33/tcl8.4.18/Unix:/home/ns/ns-allinone-2.33/tk8.4.18/Unix

    NS =/home/ns/ns-allinone-2.33/ns-2.33/

    NAM =/home/ns/ns-allinone-2.33/nam-1.13/

    Path = $ path: $ xgraph: $ ns: $ Nam


    Save

  7. Active path setting
    Type: Source ~ /. Bashrc

  8. Test (download from ns by example ).

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.