LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 10-13-2010, 04:23 AM   #1
Ramurd
Member
 
Registered: Mar 2009
Location: Rotterdam, the Netherlands
Distribution: Slackwarelinux
Posts: 703

Rep: Reputation: 111Reputation: 111
Creating a php package for Slackware 13.1


Hi all,

Running against a situation here, for which I have solutions in mind, but for some reason or another they don't really strike me as "good" solutions.

I am making a customized for myself (eg with postgreSQL support) php package. Configure and make run fine; but upon make install the make tries to access httpd.conf in the $DESTDIR/etc/httpd

My first thought is: prior to 'make install' copy the file from /etc/httpd to the target dir; however, this strikes me as an ugly solution.

Do our fellow Slackers have a better idea, or is the thought-up solution the best and safe way to go?
 
Old 10-13-2010, 07:09 AM   #2
zoran119
Member
 
Registered: Dec 2007
Posts: 217

Rep: Reputation: 18
still ugly, but symlink?

edit: what does ./configure --help say? can you specify a different location for httpd.conf?

Last edited by zoran119; 10-13-2010 at 07:33 AM.
 
Old 10-13-2010, 03:39 PM   #3
Ramurd
Member
 
Registered: Mar 2009
Location: Rotterdam, the Netherlands
Distribution: Slackwarelinux
Posts: 703

Original Poster
Rep: Reputation: 111Reputation: 111
good idea, but I think it's still ugly.

From what information I gathered, the make install takes the information from apxs2; but I can check out if ./configure gives any options regarding httpd.conf

What I think this utility will do, is enable php in the httpd.conf, which is actually not a bad idea, but would not be such a great idea if you create the package on a "clean" system and install it to an already active, configured server. Now that the file is in /etc, I guess that installpkg/upgradepkg will create an httpd.conf.new file. I think I'll take that approach and copy the httpd.conf to the $DESTDIR/etc/httpd.
 
Old 10-13-2010, 05:15 PM   #4
lumak
Member
 
Registered: Aug 2008
Location: Phoenix
Distribution: Arch
Posts: 799
Blog Entries: 32

Rep: Reputation: 111Reputation: 111
Maybe you can just do "touch $DESTDIR/etc/httpd/httpd.conf" to see what it actually puts in there... what does the slackbuild do?
 
Old 10-13-2010, 06:51 PM   #5
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,269
Blog Entries: 24

Rep: Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196Reputation: 4196
Quote:
Originally Posted by Ramurd View Post
I am making a customized for myself (eg with postgreSQL support) php package.
If you are only trying to add postgreSQL support there is an easier way!

Here are my own notes - I do this occasionally, just last week in fact:

++++++++++++++++++++++++++++++++++
Postgresql and PHP in Slackware
Slackware ships with PHP compiled wihtout Postgresql support.

To enable it you obviously need to build the postgresql package, then...

You can rebuild PHP using the --with-pgsql=shared,/usr directive, but all you really need is the module, so an easy way is to rebuild PHP using ONLY the --with-pgsql... directive, copy the module to the php extensions path and possibly edit the /etc/httpd/php.ini to enable it's use... like this:

1. Untar the php source that ships with Slackware, cd to the directory
2. ./configure --with-pgsql=shared,/usr
3. make (DO NOT RUN make install!)
4. copy .../modules/pgsql.so to /usr/lib/php/extensions/pgsql.so
5. Edit /etc/httpd/php.ini and add line 'extension=pgsql.so'

Restart apache and you should be done!

(NOTE: It is NOT necessary to edit /etc/php/php.ini to use the module!)
 
  


Reply



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
creating rpm package javimd786 Linux - Newbie 1 01-05-2010 01:02 PM
LXer: Pretending a Package is Installed by Creating an Empty Package with Checkinstal LXer Syndicated Linux News 0 05-03-2009 03:10 PM
Error creating php 5.2.8 package NetNightmare Slackware 3 02-22-2009 05:43 AM
PHP5 Upgrade Error: Missing Dependency: php = 4.3.x is needed by package php-pear vsystems Linux - Server 1 05-02-2007 07:17 AM
Creating an RPM package? WeNdeL Linux - Software 3 03-05-2003 09:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 06:00 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