LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-14-2009, 03:59 AM   #1
k_oudom
Member
 
Registered: Aug 2009
Posts: 293

Rep: Reputation: 30
How to Compile httpd-2.2.13 on CentOS 5.3?


Can someone give me the instruction on how to compile httpd-2.2.13 on a specific Linux Distributor. Assume that I'm using CentOS 5.3.

This direct download link of httpd-2.2.13: http://apache.mirrors.tds.net/httpd/httpd-2.2.13.tar.gz
 
Old 09-14-2009, 04:28 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 12,843

Rep: Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868
It depends from the options you want to enable for apache. In general running
Code:
./configure --prefix=/some/path/to/apache --enable-so
is enough if you want apache to support DSOs (like mod_php). Note that /somet/path/to/apache is the path you want to install apache.
If you want to enable more options (like mod_ssl, mod_rewrite etc), run
Code:
./configure --help
to see all the available ./configure options.

Regards

Last edited by bathory; 09-14-2009 at 04:31 AM.
 
Old 09-14-2009, 04:30 AM   #3
k_oudom
Member
 
Registered: Aug 2009
Posts: 293

Original Poster
Rep: Reputation: 30
What is the default part for apache of /some/path/to/apache on CentOS 5.3?
 
Old 09-14-2009, 04:32 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 12,843

Rep: Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868Reputation: 1868
There is no default path. You can install it where you want.
I always prefer to install apache in /usr/local/apache
 
Old 09-14-2009, 04:38 AM   #5
k_oudom
Member
 
Registered: Aug 2009
Posts: 293

Original Poster
Rep: Reputation: 30
But with default httpd come with CentOS, I can see httpd.conf is at /etc/httpd/conf.d/. It should be recommended part. What is Program Files in CentOS 5.3. In Windows is C:\Program Files\
 
Old 09-14-2009, 04:49 AM   #6
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2020 CentOS6.10 CentOS7.7 + 50+ other Linux OS, for test only.
Posts: 17,425

Rep: Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622
If you have a version of httpd installed,
please do the command : rpm -ql httpd
to get a file list with all locations.
Default for a CentOS httpd package is "--prefix=/usr/"

.....

Last edited by knudfl; 09-16-2009 at 12:45 PM.
 
Old 09-14-2009, 04:52 AM   #7
k_oudom
Member
 
Registered: Aug 2009
Posts: 293

Original Poster
Rep: Reputation: 30
After installation, how to start service? How to make it start when system boot up?
 
Old 09-14-2009, 05:15 AM   #8
lutusp
Member
 
Registered: Sep 2009
Distribution: Fedora
Posts: 835

Rep: Reputation: 102Reputation: 102
Quote:
Originally Posted by k_oudom View Post
After installation, how to start service? How to make it start when system boot up?
First start:

Code:
# service httpd start
Assure start every time computer boots (in levels 2,3,4 and 5):

Code:
# chkconfig httpd on
 
Old 09-14-2009, 07:12 AM   #9
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2020 CentOS6.10 CentOS7.7 + 50+ other Linux OS, for test only.
Posts: 17,425

Rep: Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622
... And the CentOS way to create httpd-2.2.13
is to create an rpm package :
Get this source ( which contains all patches , etc.) :
wget http://download.fedora.redhat.com/pu....11-10.src.rpm
> > httpd-2.2.11-10.src.rpm

Unpack (install) the package with the command :
rpm -Uvh httpd-2.2.11-10.src.rpm
.. and copy httpd-2.2.13.tar.gz to /usr/src/redhat/SOURCES/

Getting the required dependencies :
# yum install \
apr-devel apr-util-devel openldap-devel db4-devel \
expat-devel openssl-devel rpm-build

And using an edited spec file to build the package(s) with
# rpmbuild -bb httpd-2.2.13el5.spec

htppd.spec was edited to httpd-2.2.13el5.spec :
Edit line 9 to : Version: 2.2.13
Edit line 10 to : Release: 1el5
Un comment line 40 : # Patch55: httpd-2.2.4-oldflush.patch
Un comment line 129 : # %patch55 -p1 -b .oldflush
.. The new spec file is attached as httpd-2.2.13el5.spec.txt
.....

The build result :
usr/src/redhat/RPMS/noarch/httpd-2.2.13-10el5.noarch.rpm
/usr/src/redhat/RPMS/noarch/httpd-devel-2.2.13-10el5.noarch.rpm
/usr/src/redhat/RPMS/noarch/httpd-manual-2.2.13-10el5.noarch.rpm
/usr/src/redhat/RPMS/noarch/httpd-tools-2.2.13-10el5.noarch.rpm
/usr/src/redhat/RPMS/noarch/mod_ssl-2.2.13-10el5.noarch.rpm
.. Notice ' .noarch ' : ? a bug somewhere ?
.....
Attached Files
File Type: txt httpd-2.2.13-1el5.spec.txt (26.2 KB, 46 views)

Last edited by knudfl; 09-14-2009 at 08:44 AM.
 
Old 09-15-2009, 04:54 AM   #10
k_oudom
Member
 
Registered: Aug 2009
Posts: 293

Original Poster
Rep: Reputation: 30
That is so messy. It doesn't look like an official installation instruction. Look harder than I think.
 
Old 09-15-2009, 04:58 AM   #11
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296Reputation: 1296
Hi k_oudom,

Why would you compile at all when almost every distro has a ready to install package available? Is there any specific reason why you want to compile?

Kind regards,

Eric
 
Old 09-15-2009, 07:59 AM   #12
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2020 CentOS6.10 CentOS7.7 + 50+ other Linux OS, for test only.
Posts: 17,425

Rep: Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622
The latest official update for CentOS 5.3 is
httpd-2.2.3-22.el5.centos.1.i386.rpm

As said by @ EricTRA : Install it ... with
# yum install httpd

or use the Fedora 12 spec file + the new source,
if you really want the latest version.

The method in post # 9 is just as "official" as Fedora 12.
.. And is the official way of rebuilding a package.
.. All the mentioned packages will build in 10 minutes.
.....

Last edited by knudfl; 09-15-2009 at 08:09 AM.
 
Old 09-15-2009, 07:46 PM   #13
k_oudom
Member
 
Registered: Aug 2009
Posts: 293

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by EricTRA View Post
Hi k_oudom,

Why would you compile at all when almost every distro has a ready to install package available? Is there any specific reason why you want to compile?

Kind regards,

Eric
I create this topic since the problem about mod_ruby has not been solved. I was thinking that that error because of apache. Anyways, I want to learn about how to compile new release. They create it, so they should have a way to compile it.
 
Old 09-15-2009, 11:21 PM   #14
Smartpatrol
Member
 
Registered: Sep 2009
Posts: 196

Rep: Reputation: 38
...

Last edited by Smartpatrol; 03-11-2010 at 09:27 PM.
 
Old 09-16-2009, 07:53 AM   #15
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2020 CentOS6.10 CentOS7.7 + 50+ other Linux OS, for test only.
Posts: 17,425

Rep: Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622Reputation: 3622
Quote:
the problem about mod_ruby has not been solved
How do you know it hasn't been solved ? You never asked.

Googling .. httpd mod ruby ..
http://www.google.com/search?hl=da&s...ng&lr=&aq=&oq=
has : "mod_ruby Wiki (en) - Installing mod_ruby"
http://wiki.modruby.net/en/?InstallGuide
in the first or third hit.

And why ask for httpd-2.2.13, when you as well can rebuild
the version for CentOS 5.x = httpd-2.2.3 ?
http://mirror.centos.org/centos/5.3/...centos.src.rpm
> > httpd-2.2.3-22.el5.centos.src.rpm
.....

Last edited by knudfl; 09-16-2009 at 07:56 AM.
 
  


Reply

Tags
el5


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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



Similar Threads
Thread Thread Starter Forum Replies Last Post
Unable to start apache on CentOS Linux with error Starting httpd: Syntax error on lin pkumar2533 Linux - Newbie 9 08-26-2009 07:48 AM
(CentOS 5.3 server) httpd.conf configuration issue involving DirectoryIndex xshad0wfx Linux - Server 4 06-19-2009 10:32 PM
Starting httpd: httpd: Syntax error on line 209 of /etc/httpd/conf/httpd.conf: Syntax sethukpathi Linux - Networking 6 04-12-2008 11:26 AM
how to compile c++ programs in centos version dilinjd Linux - General 2 04-08-2007 05:32 PM
how I can centos ntfs compile? Grave Linux - General 2 12-23-2005 07:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration