image
image

Go Back   macosx.com > Mac Help Forums > Unix & X11

Reply
 
Thread Tools
  #1  
Old February 26th, 2006, 05:14 PM
Florida Mac User
 
Join Date: Nov 2000
Location: Jacksonville, FL
Posts: 28
Thanks: 0
Thanked 0 Times in 0 Posts
gduncan is on a distinguished road
Question Need help compiling source code

I'm not quite up to speed on the UNIX side of Mac OS X, but I'm trying to learn. Honestly, it often throws me for a loop! Here is my dilemma:

I'm trying to compile source code for programs that track earth-orbiting satellites. The software in question is Predict and gsat. Here is the link to the website where you can download the Predict/gsat packages and here is the link to the website that explains how to compile it for OS X.

When I try to execute the "./configure" command in the Terminal per the instructions I'm confronted with the following message:

Last login: Thu Feb 23 21:46:28 on ttyp3
Voyager:~ root# cd /users/gduncan/desktop/predict/
Voyager:/users/gduncan/desktop/predict root# ./configure
One moment please... ld: can't use -s with input files containg indirect symbols (output file must contain at least global symbols, for maximum stripping use -x)
Compilation failed. Are you sure you have a C compiler (gcc) installed?
Voyager:/users/gduncan/desktop/predict root#


I thought sure that I have a C compiler installed. I've certainly installed the Developer Tools.

Any ideas? Thanks...

Last edited by gduncan; February 26th, 2006 at 09:28 PM.
Reply With Quote
  #2  
Old March 2nd, 2006, 06:27 PM
spb spb is offline
Registered User
 
Join Date: Dec 2004
Posts: 138
Thanks: 0
Thanked 0 Times in 0 Posts
spb is on a distinguished road
The command:

which gcc

should show you if gcc is in your path.

I'm doubtful that this is the problem...

It looks like there is a problem with the configure script and ld. The output says that there is a problem with the flag -s so maybe you can look at the configure script and see where the -s comes from and remove it. A better approach would be to see if you can pass to the configure script options -- for instance you might be able to pass LDFLAG

./configure LDFLAG=-x

What can and can't be passed to configure will be in the documentation. Is there a README file that tells you about configure?
Reply With Quote
  #3  
Old March 2nd, 2006, 06:46 PM
tomdkat's Avatar
Registered User
 
Join Date: Aug 2005
Posts: 197
Thanks: 6
Thanked 0 Times in 0 Posts
tomdkat is on a distinguished road
Does OS X come with the GNU linker? Some open source apps assume use of GNU build tools and that can cause problems on systems that don't have GNU build tools involved.

Peace...
Reply With Quote
  #4  
Old March 5th, 2006, 04:05 PM
Florida Mac User
 
Join Date: Nov 2000
Location: Jacksonville, FL
Posts: 28
Thanks: 0
Thanked 0 Times in 0 Posts
gduncan is on a distinguished road
Well, I must say thank you for all the advice. I've tried all the above suggestions, but nothing has worked so far.

I may end up re-formatting the hard drive and re-installing the system software. Perhaps I'll even run down to the Apple Store and buy 10.4 Tiger.
Reply With Quote
  #5  
Old March 5th, 2006, 08:59 PM
macbri's Avatar
Mac (r)evolution
 
Join Date: Jun 2005
Location: Ireland
Posts: 250
Thanks: 1
Thanked 0 Times in 0 Posts
macbri is on a distinguished road
Lightbulb

Hi -

Try removing the offending "-s" flag from the compile line in ./configure so the line now reads:

cc -Wall installer.c -lncurser -o installer

Admittedly I compiled this successfully without the change above on both 10.3.9 and 10.4.5 with no problems (a few warnings on the latter, but otherwise ok), but this might get you started.
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
compiling unpv12e source tblount Unix & X11 5 August 18th, 2008 06:14 AM
shows php source code instead of result jsn Software Programming & Web Scripting 1 October 30th, 2005 06:32 AM
Compiling C++ code SpacemanSpiff2 Software Programming & Web Scripting 7 May 6th, 2005 10:06 PM
Compiling Java Source Code RockyMorris Software Programming & Web Scripting 2 May 23rd, 2002 01:17 PM
Compile Source Code to Cocoa? ITz The MaN Mac OS X System & Mac Software 0 October 15th, 2000 07:33 PM


All times are GMT -5. The time now is 06:09 AM.


Mac Support® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0
Copyright 2000-2008 DigitalCrowd, Inc.