installing via ports: possible to exclude development headers?

installing via ports: possible to exclude development headers?

Post by Alan Murre » Wed, 02 Oct 2002 09:44:04



Hello, All,

You will have to forgive the probable ignorance of this question, as i
come from a Linux background.  Also, I am not trying to start a "holy
war" here, only after some information.

My boss is asking me to evaluate different OS's for a project he is
workingon.  I knew form the get-go that it would be either Linux or a
BSD, and I'm just trying to decide which "flavour".  My choices are
basically down to FreeBSD and Mandrake Linux.

While I really like FreeBSD'd reputation for stability, the thing that
is really attractive to me for Mandrake (other than the fact that that
is what I use at home, bit for my servers and desktop) is that it uses
the RPM "system", which allows one to install only the binaries
necessary for the operation of the daemon/program/etc (i.e., you can
seperate out the development headers, which generally aren;t required
on a production machine)

Is it possible to do this with FreeBSD, or when you install something
using the ports system, it installs as if from source (i.e.,
*everything*, including header files, etc.)

In addition, while I have not seen what the FreeBSD "ports" look like,
I do know that through the use of "spec" files (in Linux RPM systems),
it is easy to keep record of how certain software was installed
(configuration-wise), and so easy for someone to reproduce the install
should I get hit by a bus or something :-)

Is there something similar for the "ports"?

Thanx, in advance, for the help.


 
 
 

installing via ports: possible to exclude development headers?

Post by Warren Bloc » Wed, 02 Oct 2002 10:02:08



> While I really like FreeBSD'd reputation for stability, the thing that
> is really attractive to me for Mandrake (other than the fact that that
> is what I use at home, bit for my servers and desktop) is that it uses
> the RPM "system", which allows one to install only the binaries
> necessary for the operation of the daemon/program/etc (i.e., you can
> seperate out the development headers, which generally aren;t required
> on a production machine)

> Is it possible to do this with FreeBSD, or when you install something
> using the ports system, it installs as if from source (i.e.,
> *everything*, including header files, etc.)

It installs from source, but you can remove the source afterwards with
the "clean" option to make.

--
Warren Block * Rapid City, South Dakota * USA

 
 
 

installing via ports: possible to exclude development headers?

Post by Erik Nygre » Wed, 02 Oct 2002 15:24:16


...

Quote:> Is it possible to do this with FreeBSD, or when you install something
> using the ports system, it installs as if from source (i.e.,
> *everything*, including header files, etc.)

You might install packages, using pkg_add. Packages are basically just
compiled ports, and you might want to create packages from your ports
to speed up a restore etc.
Also, as someone else mentioned, ports can clean up after themselves.

Quote:

> In addition, while I have not seen what the FreeBSD "ports" look like,
> I do know that through the use of "spec" files (in Linux RPM systems),
> it is easy to keep record of how certain software was installed
> (configuration-wise), and so easy for someone to reproduce the install
> should I get hit by a bus or something :-)

You can track your ports using pkg_info or if you want it to be easy,
by installing portupgrade from ports.
You can also make a package of each port you install (portupgrade helps
with this as well) and that way make sure you are able to reproduce the
exact versions of the software you installed.
The configuration of a port is done at compile-time with various flags
to make, or at run-time, usually by files in /usr/local/etc.
You will get the compile-settings in the package, and the default settings.
If you change defaults later, you will have to keep you backups fresh.

--
Erik Nygren
e r i k { a t } s w i p { d o t } n e t
Linux - If you hate Microsoft, FreeBSD - If you love Unix

 
 
 

installing via ports: possible to exclude development headers?

Post by Richard Cale » Wed, 02 Oct 2002 22:01:01


am> Is it possible to do this with FreeBSD, or when you install something
am> using the ports system, it installs as if from source (i.e.,
am> *everything*, including header files, etc.)

Well, if you install something which is intended for building things
(eg a library) you will get the header files. I can't see why you
wouldn't. Even as an old fart who still thinks a megabyte is a lot of
space, and a gigabyte unimaginable, I can't say I hav a problem with a
few K of headers. You never know, they may come in useful someday.

am> In addition, while I have not seen what the FreeBSD "ports" look like,
am> I do know that through the use of "spec" files (in Linux RPM systems),
am> it is easy to keep record of how certain software was installed
am> (configuration-wise), and so easy for someone to reproduce the install
am> should I get hit by a bus or something :-)

A port, physically, is a directory with some small files in it.

Generally, ports are just fire-and-forget. ie you don't have to give
many parameters for specific configurations, common variations are
often there as alternative ports. This means you only have to know
that it was, say, apache13-modssl which was installed, rather than the
vanilla `apache13' port.

If it gets much further out than that I would generally build from real
source (as I do for apache), but that is probably just old-fartism
again.

There is a database of installed ports and packages you can query, but
more interestingly for you perhaps there is a package called
postupgrade which uses that database and can be asked to upgrade
things which are installed together with any dependencies etc. I don't
know if it can run off a backed-up copy of the database or something
to re-create a previous state.

--

                                                 |<

 
 
 

installing via ports: possible to exclude development headers?

Post by Simon Barne » Wed, 02 Oct 2002 21:43:01


Hello Alan,

Quote:> Is it possible to do this with FreeBSD, or when you install something
> using the ports system, it installs as if from source (i.e.,
> *everything*, including header files, etc.)

For libraries, you will need these header, and they are usually installed in
/usr/local/include or /usr/X11R6/include (for X11 apps).

When you type "make install clean", then the source distribution is
automatically fetched, the archive is put into /usr/ports/distfiles). Then this
archive is extracted into a working dir (usually diroftheport/work), and the
compilations begins (evtl. after some patches have bin applied automatically).
Finally, the working dir is erased.

Quote:> (configuration-wise), and so easy for someone to reproduce the install
> should I get hit by a bus or something :-)

The compile time configuration (i.e. the GNU autoconf --prefix=lalalala
--foobar=lajf) are provided by the port system, together with compile time and
run time dependencies of the application - no need to do something manually
here.

Some ports offer special compile time options, but they are usually only flags
that are passed to make, e.g. "make FEATURE1=on FEATURE2=off install clean", so
when you keep record of these lines (e.g in a shell script), you'll be fine.

Configuration files are usually put into $PREFIX/etc, and ports should provide
examples of these files as $PREFIX/etc/config.sample, which have to copied to
$PREFIX/etc/config. When you de-install a port, only the .sample file is
deleted.

Unfortunately, not all the ports seem to follow this policy, so it's a good idea
to make regular backups of your etc-dirs (or to move the files away before you
de/re-install a piece of software).

Regards,
 Simon

 
 
 

1. Header file search path for gcc (installed via FSFgcc)

I've installed gcc using te the FSFgcc package from http://smc.vnet.net/ on my
2.5.1 machine.

When I run gcc, it's picking up the includes from /usr/include before
/opt/FSFgcc/lib/gcc-lib/sparc-sun-solaris2.5/2.7.2/include.  This breaks code
that's including stdarg.h. If I add
a -I/opt/FSFgcc/lib/gcc-lib/sparc-sun-solaris2.5/2.7.2/include everything
works fine.

Is there another installation step I should go through?  The FSFgcc package
doesn't include fixincludes.

======================================================
James Moore             Real-time / VxWorks consulting
Banshee Software            

2. Solaris: root cron jobs halting

3. Installing Linux via NFS, possible??????

4. does yaboot have to be this difficult?

5. Is it possible to install redhat via FTP with DHCP?

6. where's libc 5.4.11+?

7. Possible to install Linux via NFS?

8. *Long* pause when launching some programs under X

9. 2.6x86 install via PCMCIA -- Not possible?

10. ssh access not via IP but via "key" (or on another way) possible?

11. Is it possible to exclude telnetd Messages from syslog ?????

12. excluding with /etc/exclude.rootvg

13. is it possible to exclude telnetd Messages from syslog on SCO unix 5 and/or 3 ???