Re: [gtk-list] Help with compiling GTK program



On Wed, 12 May 1999 17:43:12 -0500, gtk-list@redhat.com (Brit) wrote:
> I am using an SGI Octane.

So do I.

> I installed GIMP and GTK.
> Next I cut and pasted the program that creates a 200x200 pixel window
> which is on the "Get Started"
> page of.... http://www.gtk.org/tutorial/gtk_tut-2.html.
> 
> I saved this program as base.c
> in my home directory.
> I try compile the program by typing:
> 
> gcc base.c -o base `gtk-config --cflags --libs`
> 
> This is the errors that I got:
> brit % gcc base.c -o base `gtk-config --cflags --libs`
> Cannot execute binary file
> /usr/local/bin/gcc - Exec format error
> 
> Please, What am I doing wrong?

You are using a gcc C compiler that was compiled for a different platform
than the Octane. Try using another gcc, or try using the SGI MipsPRO C
compiler:

  cc base.c -o base `gtk-config --cflags --libs`

If that fails, try:

  cc -o32 base.c -o base `gtk-config --cflags --libs`

Oh, and by the way: tell your system administrator that is a *very* bad
idea to mount something over /usr/local on SGI 6.x systems. Some brave
souls at SGI decided that part of the system setup data, software
licenses, and Netscape plugins should be in /usr/local instead of the more
obvious /usr directory. If you mount something over /usr/local, you'll
lose that functionality; an indication of this is that Netscape complains
at startup about certain icons it can't find. An even worse idea is to
mount an NFS volume over it that is not even slightly compatible with the
Octane's own binary format. 


Erik

-- 
J.A.K. (Erik) Mouw, Information and Communication Theory Group, Department
of Electrical Engineering, Faculty of Information Technology and Systems,
Delft University of Technology, PO BOX 5031,  2600 GA Delft, The Netherlands
Phone: +31-15-2785859  Fax: +31-15-2781843  Email J.A.K.Mouw@its.tudelft.nl
WWW: http://www-ict.its.tudelft.nl/~erik/




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]