Skip to main content

Xgraph [dialog.o] error

If you are installing ns2 allinone package in fedora or ubuntu or any other linux, all the packages will be installed successfully. Occasionally the recent releases of linux flavors failed to install xgraph.

Problem:

The possible error you may get is [dialog.o] error,

Solution:

  1. Open the file dialog.c which is available under the folder xgraph-12.1/ (this is in my case)
  2. Find out the function getline() (will be at two places), usually line number 780 and 891 or 889, replace getline() function to newgetline() (at the both the places)
  3. save the file and at the prompt give ./configure
  4. give the command make

If there are no errors, xgraph will work now..

Comments

  1. I got the following error while patching sip 2.26 to ns 2.26



    tclcl-mappings.h: In static member function ‘static int TclObjectHelper::dispatch_(void*, Tcl_Interp*, int, char**)’:
    tclcl-mappings.h:51: error: incomplete type ‘Tcl’ used in nested name specifier
    tclcl-mappings.h:52: error: invalid use of undefined type ‘struct Tcl’
    tclcl-mappings.h:41: error: forward declaration of ‘struct Tcl’
    tclcl-mappings.h:57: error: invalid use of undefined type ‘struct Tcl’
    tclcl-mappings.h:41: error: forward declaration of ‘struct Tcl’
    make: *** [Tcl.o] Error 1
    tclcl-1.0b13 make failed! Exiting ...

    ReplyDelete
  2. i got the following error while patching SIP in ns2.27 and my OS ubuntu 8.10


    make: Nothing to be done for `all'.
    otcl-1.8 has been installed successfully.
    ============================================================
    * Build Tclcl-1.15
    ============================================================
    No .configure file found in current directory
    Continuing with default options...
    checking build system type... i686-pc-linux-gnu
    checking host system type... i686-pc-linux-gnu
    checking target system type... i686-pc-linux-gnu
    checking for gcc... gcc
    checking for C compiler default output file name... a.out
    checking whether the C compiler works... yes
    checking whether we are cross compiling... no
    checking for suffix of executables...
    checking for suffix of object files... o
    checking whether we are using the GNU C compiler... yes
    checking whether gcc accepts -g... yes
    checking for gcc option to accept ISO C89... none needed
    checking for g++... no
    checking for c++... no
    checking for gpp... no
    checking for aCC... no
    checking for CC... no
    checking for cxx... no
    checking for cc++... no
    checking for cl.exe... no
    checking for FCC... no
    checking for KCC... no
    checking for RCC... no
    checking for xlC_r... no
    checking for xlC... no
    checking whether we are using the GNU C++ compiler... no
    checking whether g++ accepts -g... no
    checking how to run the C preprocessor... gcc -E
    checking for grep that handles long lines and -e... /bin/grep
    checking for egrep... /bin/grep -E
    checking for ANSI C header files... yes
    checking for sys/types.h... yes
    checking for sys/stat.h... yes
    checking for stdlib.h... yes
    checking for string.h... yes
    checking for memory.h... yes
    checking for strings.h... yes
    checking for inttypes.h... yes
    checking for stdint.h... yes
    checking for unistd.h... yes
    checking for string.h... (cached) yes
    checking for main in -lXbsd... no
    checking for socket in -lsocket... no
    checking for gethostbyname in -lnsl... yes
    checking for dcgettext in -lintl... no
    checking for getnodebyname in -ldnet_stub... no
    checking that g++ can handle -O2... no
    checking standard STL is available... no
    checking for ranlib... ranlib
    checking for snprintf... yes
    checking for ANSI C header files... (cached) yes
    checking for strtoq... yes
    checking for strtoll... yes
    checking size of long... 4
    checking for __int64_t... no
    checking for long long... yes
    checking for int64_t... yes
    checking which kind of 64-bit int to use... int64_t
    checking for tcl.h... -I../tcl8.4.18/generic
    checking for tclInt.h... -I../tcl8.4.18/generic
    checking for libtcl8.4... -L../tcl8.4.18/unix -ltcl8.4
    checking for init.tcl... ../tcl8.4.18/library
    checking for http.tcl... ../tcl8.4.18/library/http
    checking Tcl http.tcl library... yes
    checking for tclsh8.4.18... no
    checking for tclsh8.4... /home/karthik/ns-allinone-2.27/bin/tclsh8.4
    checking for tk.h... -I../tk8.4.18/generic
    checking for libtk8.4... -L../tk8.4.18/unix -ltk8.4
    checking for tk.tcl... ../tk8.4.18/library
    checking for otcl.h... -I../otcl-1.13
    checking for libotcl1.13... -L../otcl-1.13 -lotcl
    checking for X11 header files
    checking for X11 library archive
    checking for XOpenDisplay in -lX11... yes
    checking for XShmAttach in -lXext... yes
    checking for zlib.h... no
    checking for libz1.1.3... no
    No explicit static compilation flag; setting V_STATIC to ""
    checking for dlopen in -ldl... yes
    checking for a BSD-compatible install... /usr/bin/install -c
    configure: creating ./config.status
    config.status: creating Makefile
    config.status: creating config.h
    config.status: config.h is unchanged
    rm -f tcl2c++
    g++ -o tcl2c++ tcl2c++.o
    make: g++: Command not found
    make: *** [tcl2c++] Error 127
    tclcl-1.15 make failed! Exiting ...
    See http://www.isi.edu/nsnam/ns/ns-problems.html for problems
    karthik@karthik-laptop:~/ns-allinone-2.27$

    ReplyDelete
  3. I am trying to run dsr.tcl... simulation shows a "Segmentation fault" but animation is simulated (under NAM window) correctly. also xgraph gives a error "unknown line type" - any suggestions ?

    ReplyDelete
  4. Nilesh Shahane27 May 2011 at 18:10

    Thank You!
    I am using ns2.34 on Fedora 13 and your solution worked for me.
    Thanks again.

    ReplyDelete
  5. i got the following errors to run the command make install

    /usr/bin/install -c xgraph '/usr/local/bin'
    /usr/bin/install: cannot create regular file `/usr/local/bin/xgraph': Permission denied
    make[1]: *** [install-binPROGRAMS] Error 1
    make[1]: Leaving directory `/home/ns/xgraph-12.1.orig'
    make: *** [install-am] Error 2

    any suggestion

    ReplyDelete

Post a comment

Popular posts from this blog

Implementing a new system call in Kernel version 2.6.32

A system call is used by application or user programs to request service from the operating systems. Since the user programs does not have direct access to the kernel whereas the OS has the direct access. OS can access the hardware through system calls only. The following files has to be modified for implementing a system call /usr/src/linux-2.6.32.5/arch/x86/kernel/syscall_table_32.S /usr/src/linux-2.6.32.5/arch/x86/include/asm/unistd_32.h /usr/src/linux-2.6.32.5/include/linux/syscalls.h /usr/src/linux-2.6.32.5/Makefile New set of files to be created Create a new directory newcall/ inside the path “ /usr/src/linux-2.6.32.5/ ” Create new files Makefile, newcall.c and put them in the /usr/src/linux-2.6.32.5/newcall/ folder Create new user files (in any folder of Linux) to test the system call testnewcall.c, testnewcall.h (created in /home/pradeepkumar ) syscall_table_32.S Find the file /usr/src/linux-2.6.32.5/arch/x86/kernel/syscall_tab

How to Access MOODLE in Intranet and Internet

When Moodle is accessed either in Intranet or internet, there will not be any issue. But occasions when the MOODLE Site has to be accessed both in the intranet and in the Internet, here is a simple trick Server Used: IBM Blade Servers Operating system: Windows Server 2008 Moodle Version: 2.4 WAMP Server is used. Number of Users: 3000 (Students) + 200 (Faculty) Open the config.php from ~/moodle/config.php include these lines $CFG->wwwroot = 'http://'.$server_id.'/vitcc'; $CFG->dataroot  = 'C:\\wamp\\moodledata'; before the following line $CFG->directorypermissions = 07xx; Restart the WAMP Server and you can Check MOODLE Site both in Internet and Intranet. The above Image tells the intranet Link and the internet link can be opened outside the campus network

Electrical Machine Design (equations)

Factors DC Machine Transformers Induction Machines Synchronous Machines Output Equation P a =C o D 2 Ln, where Pa=P/h for generators, Pa=P for motors For Single Phase Q=2.22 f B m A i K w A w d 10 -3 For Three Phase Q=3.33 f B m A i K w A w d 10 -3 Q=C o D 2 L n s KVA Input Q= HP * 0.746 / Cos f * h Q=C o D 2 L n s KVA Input Q= HP * 0.746 / Cos f * h For Turbo alternators Q=1.11B av ac K ws V a 2 L 10 -3 /n s Output Coefficient C o =B av ac* 10 -3 where Bav-magnetic loading and ac - electric loading DNA C o =11 K ws B av ac 10 -3 C o =11 K ws B av ac 10 -3 Choice of Magnetic Loading Flux Density in Teeth Frequency of Flux Reversals Size of machine DNA Magnetizing current, Flux Density, Iron loss Iron loss, Stability, Voltage Rating, Parallel Operation, Transient ShortCircuit current