Re: pkg_list & applications from source
- From: Jason Bourne <j_bourne_treadstone@xxxxxxxxxxx>
- Date: Tue, 29 May 2007 22:41:21 GMT
DanielP wrote:
Disclaimer: I have most of the FreeBSD handbook, did google searches and
so on.
Need: actual search parameters (example: freebsd register source
applications) or if you want, actual steps.
I installed apache, php and a few other applications from source. Because
I needed additional functionality I could not get when installing from the
package or ports. Apache and php and the other applications are working
perfeclty well and are very stable. The problem is now I can't install
anything else that requires apache, php and so on from packages OR ports,
because it tries to install my already installed applications. So I need
a way to register apache, php and so on to pkg_list, however I don't know
if editing pkg_list is enough or if I need to take additional steps to
make
sure my system stays stable. If I need to install everything else from
source, well so be it, but I would like any assistance I can get.
Thank you!
DP
I know this isn't the answer you are asking for, but consider a different
direction. First a little background: Many years ago I used to manually
build Apache so I could build PHP into it statically. It wasn't too
terribly difficult to repeat later when I needed to upgrade but it
eventually got old. So for the sake of maintainability I switched to using
the port build of Apache and DSOs.
The gist of where I'm headed here is "Why not use the ports system?". I do
understand there may be some edge configuration out there for which the
port build possibly doesn't cut it. Delve a little deeper into the
functionality of the ports system and you may find that what you need to
know is how to configure a port build.
Caveat here: I use Apache 2.2.x these days and it has been quite some time
since I've seen a 1.3.xx build, so I'm talking about what I do here. YMMV
If you read through the Makefile and Makefile.modules files you will see
numerous make "WITH_SOMETHING=yes" switches. I know there are lots of them,
and it can take quite a while to get through all of them but when you do
and you have decided on a configuration the config(s) can be placed
in /etc/make.conf. This will also allow one to portupgrade Apache 2.2.x
later and it will build/update the same as you initially configured it.
Example from my /etc/make.conf:
#For Apache-2.2.4 Build
WITH_MPM=worker
WITH_THREADS=yes
WITHOUT_AUTHN_MODULES=yes
WITH_CUSTOM_AUTHZ=authz_host
WITHOUT_DAV_MODULES=yes
WITHOUT_LDAP_MODULES=yes
WITHOUT_PROXY_MODULES=yes
WITHOUT_SUEXEC_MODULES=yes
WITH_THREADS_MODULES=yes
WITH_CACHE_MODULES=yes
WITH_SSL_MODULES=yes
WITH_AUTH_MODULES=yes
WITH_MISC_MODULES=yes
WITH_CUSTOM_EXPERIMENTAL=ext_filter
With regard to PHP/PHP-extensions, many ports these days have a "make
config" menu that comes up and displays all the "WITH_BLAH=yes" build
options and allows the chosen configuration to be saved. For example, if
you look in /var/db/ports/php5-extensions there is a file named "options"
that (in my case here) looks like this:
# This file is auto-generated by 'make config'.
# No user-servicable parts inside!
# Options for php5-extensions-1.1
_OPTIONS_READ=php5-extensions-1.1
WITHOUT_BCMATH=true
WITH_BZ2=true
WITHOUT_CALENDAR=true
WITH_CTYPE=true
WITH_CURL=true
WITHOUT_DBA=true
WITHOUT_DBASE=true
WITH_DOM=true
WITHOUT_EXIF=true
WITHOUT_FILEINFO=true
WITH_FILTER=true
WITHOUT_FRIBIDI=true
WITHOUT_FTP=true
WITHOUT_GD=true
WITHOUT_GETTEXT=true
WITHOUT_GMP=true
WITHOUT_HASH=true
WITH_ICONV=true
WITHOUT_IMAP=true
WITHOUT_INTERBASE=true
WITH_JSON=true
WITHOUT_LDAP=true
WITHOUT_MBSTRING=true
WITHOUT_MCRYPT=true
WITHOUT_MHASH=true
WITHOUT_MING=true
WITHOUT_MSSQL=true
WITH_MYSQL=true
WITHOUT_MYSQLI=true
WITHOUT_NCURSES=true
WITHOUT_ODBC=true
WITHOUT_OPENSSL=true
WITHOUT_PCNTL=true
WITH_PCRE=true
WITHOUT_PDF=true
WITH_PDO=true
WITH_PDO_SQLITE=true
WITHOUT_PGSQL=true
WITH_POSIX=true
WITHOUT_PSPELL=true
WITHOUT_READLINE=true
WITHOUT_RECODE=true
WITH_SESSION=true
WITHOUT_SHMOP=true
WITH_SIMPLEXML=true
WITHOUT_SNMP=true
WITHOUT_SOAP=true
WITH_SOCKETS=true
WITH_SPL=true
WITH_SQLITE=true
WITHOUT_SYBASE_CT=true
WITHOUT_SYSVMSG=true
WITHOUT_SYSVSEM=true
WITHOUT_SYSVSHM=true
WITHOUT_TIDY=true
WITH_TOKENIZER=true
WITHOUT_WDDX=true
WITH_XML=true
WITH_XMLREADER=true
WITH_XMLRPC=true
WITH_XMLWRITER=true
WITH_XSL=true
WITHOUT_YAZ=true
WITH_ZIP=true
WITH_ZLIB=true
So if you don't like the config and want to start over it's as easy as "make
rmconfig". Most ports that have this functionality will automagically pop
up the config menu screen when you do "make" if there is no pre-existing
options file, but "make config" does the same thing manually. This saved
build configuration will also be used for upgrades such as portupgrade,
without having to reinvent the wheel.
What I'm suggesting here is to work within the ports system. You will be
much better off in the long run with a system that is easy to update. If
the option(s) you absolutely need isn't available from the standard port
Makefile, make a backup copy and add it into a manually modified Makefile.
Most of the edge option situations will be an option to the ./configure
script and once you know what you need add it to the appropriate location
in your modified Makefile and away you go.
The downside to hacking Makefiles is they'll be clobberred the next time you
update your ports tree. So I look upon Makefile hacking as an extreme last
resort, and in most cases is simply unnecessary. In the case where it may
be something others may desire a quick message with diff to the port
maintainer and the maintainer might just add it in if it's simple and it
won't break anything.
(And yes - the Apache config I used above took some hair pulling to get it
*exactly* the way I wanted it, but worth the time because with the options
permanently placed into /etc/make.conf I don't have to lather, rinse,
repeat...)
My suggestion - "Use the PORTS young Luke Skywalker!" Going down the road
you are considering will only bring more trouble than it's worth later down
the road.
-Jason
.
- Follow-Ups:
- Re: pkg_list & applications from source
- From: Conrad J. Sabatier
- Re: pkg_list & applications from source
- References:
- pkg_list & applications from source
- From: DanielP
- pkg_list & applications from source
- Prev by Date: pkg_list & applications from source
- Next by Date: Re: ThinkPad R60, no sound, no /dev/pcm (6.2-RELEASE)
- Previous by thread: pkg_list & applications from source
- Next by thread: Re: pkg_list & applications from source
- Index(es):
Relevant Pages
|