The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Operating Systems > Linux > SuSE
.
google unix.com



SuSE SUSE Linux is a major operating system. The developer rights are owned by Novell, Inc.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
How to compile from source code? wrapster UNIX and Linux Applications 1 05-27-2008 05:03 PM
Suse LINUX hassan2 SuSE 1 06-24-2004 10:38 AM
error trying to compile a c++ source file ldrojasm High Level Programming 1 03-05-2002 02:12 PM
compile C under linux? ctchung High Level Programming 2 09-20-2001 11:26 PM
compile rpm-4.0 source eddie High Level Programming 2 08-28-2001 06:59 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 05-19-2006
Mark Ward Mark Ward is offline
Registered User
  
 

Join Date: Sep 2004
Location: Kent, UK
Posts: 28
How do I compile source undfer Suse Linux?

I've been usuing Suse 9.1 & 10 on 2 different machines for a while and have so far relied on ready compiled versions of programs in RPMs in order to install them.

I'm unclear what is envolved in compiling from the source code myself. I did a general google on the topic and found some unclear information that listed a mass of files I'd need to add to my systems and some vague intructions.

I've been considering a number of applications (including Zone-Minder) that I would like to run under Suse, but there are not compiled versions of the latest revisions available.

Could someone shed some light on the process "work-flow" of compiling for me please? Any link to a "How-To" would be appreciated. I'm sure I'll be able to do it, I just can't seem to work out what I should be doing.

Is there a rpm with all the necessary files I'll need to add to my systems?

Many thanks,

Mark.
  #2 (permalink)  
Old 05-20-2006
zazzybob's Avatar
zazzybob zazzybob is offline Forum Advisor  
Registered Geek
  
 

Join Date: Dec 2003
Location: Melbourne, Australia
Posts: 2,100
A lot of the time you'll find that a compilation sequence is generally as follows:

# tar xvzf somefile-version.tar.gz
# cd some_dir_created_by_extraction
# ./configure
# make
# make install

./configure should tell you if you're missing anything. This will differ from package to package, but (generally) a file named README and/or INSTALL will exist in the root of the tarball that should have clear compilation/installation instructions. The documentation should also indicate whether or not any prerequisite packages are required.

Cheers
ZB
  #3 (permalink)  
Old 05-25-2006
Mark Ward Mark Ward is offline
Registered User
  
 

Join Date: Sep 2004
Location: Kent, UK
Posts: 28
Thanks for that! I've been compiling for a while without even knowing it!

There was me thinking there was this "Dark Art" that someone may one day let me in on so long as I was sworn to secrecy.

Cheers!

Mark.
  #4 (permalink)  
Old 05-26-2006
Mark Ward Mark Ward is offline
Registered User
  
 

Join Date: Sep 2004
Location: Kent, UK
Posts: 28
It works!... However.. when attempting to compile php-4.4.2.tar.gz for Suse 10.1 I get the following errors


Code:
# ./configure

creating cache ./config.cache
checking for egrep... grep -E
checking for a sed that does not truncate output... /usr/bin/sed
checking host system type... i686-pc-linux-gnu
checking for gcc... gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking whether gcc and cc understand -c and -o together... yes
checking how to run the C preprocessor... gcc -E
checking for AIX... no
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking for re2c... exit 0;
checking whether ln -s works... yes
checking for gawk... gawk
checking for bison... no
checking for byacc... no
configure: warning: You will need bison if you want to regenerate the PHP parsers.
checking for flex... lex
checking for yywrap in -ll... no
checking lex output file root... ./configure: line 2540: lex: command not found
configure: error: cannot find output from lex; giving up

#

Is this simply a case of searching for a "lex" aaand "bison" package in YAST and installing them?

[EDIT] Since I had a fresh backup I thought I'd give it a try and have succesfully compiled for Suse 10.1 Unfortunately the resulting files do not contain the packages I was looking for, but that's fine. I'll search a little more.

Now I have a folder of PHP-4.4.2 compiled for Suse10.1 how would I create an RPM to enable others to use it? Actually, how can I check to make sure it's valid? I didn't get any errors compiling.... Is that enough?

Thanks,

Mark.

Last edited by Mark Ward; 05-26-2006 at 02:40 PM..
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 01:19 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0