XtVaAppInitialize not found

From: scott (scottamillard_at_hotmail.com)
Date: 08/24/04


Date: Tue, 24 Aug 2004 19:31:11 +0100

hi all

just trying to compile a program, i know it probs won't do anything as such,
but im just trying to learn.

when i try to compile it i get the message

: undefined reference to 'XtVaAppInitialize'
/tmp/ccUiaRHT.o(.eh_frame+0x11): undefined reference to
'__gxx_personality_v0'

the code is

#include <X11/Intrinsic.h>
#include <X11/StringDefs.h>
#include <X11/Xaw/Form.h>

#include <stdio.h>
#include <stdlib.h>

int main (int argc, char **argv)
{
        XtAppContext appContext;
        Widget toplevel, form;

        toplevel = XtVaAppInitialize(&appContext,
                                                    "2D-Editor",
                                                    NULL,
                                                    0,
                                                    &argc,
                                                    argv,
                                                    NULL,
                                                    NULL);
}

im using
gcc -o myProgram temp.cpp
to compile it, and if i take out the XtVAppInitialize function out it
compiles ok.

can some one tell what stupid mistake im making ?

Thx for the help

Scott.



Relevant Pages

  • Re: Prolog & C linking Problem
    ... >> I am trying to compile Prolog and C using plld. ... PL_initialise_ is an undefined reference ...
    (comp.lang.prolog)
  • How can I compile PF without option PFIL_HOOKS defined in the kernel conf file?
    ... kernel conf file to try to get PF compile into the kernel, ... PF failed to compile; ... : undefined reference to `pfil_head_get' ... Will this fix the problem? ...
    (comp.unix.bsd.openbsd.misc)
  • gprof
    ... I'm trying to compile my C application with gprof but it is not working. ... This is a multithreaded program that use mysql and openssl libraries. ... /lib/libcrypto.so.4: undefined reference to `sysconf' ...
    (freebsd-questions)
  • Re: gprof
    ... I'm trying to compile my C application with gprof but it is not working.. ... This is a multithreaded program that use mysql and openssl libraries. ... /lib/libcrypto.so.4: undefined reference to `sysconf' ...
    (freebsd-questions)
  • Re: uudecode for Red Hat 9.0?
    ... > compile on Red Hat Linux. ... and they should compile fine ... ... /tmp/ccXtLHVa.o: undefined reference to `setmode' ... ld returned 1 exit status ...
    (comp.os.linux.misc)