The FreeBSD Diary

The FreeBSD Diary (TM)

Providing practical examples since 1998

If you buy from Amazon USA, please support us by using this link.
[ HOME | TOPICS | INDEX | WEB RESOURCES | BOOKS | CONTRIBUTE | SEARCH | FEEDBACK | FAQ | FORUMS ]

Things look quiet here. But I've been doing a lot of blogging at dan.langille.org because I prefer WordPress now. Not all my posts there are FreeBSD related. I am in the midst of migrating The FreeBSD Diary over to WordPress (and you can read about that here). Once the migration is completed, I'll move the FreeBSD posts into the new FreeBSD Diary website.

Building a port - background info on make 4 October 1998
Need more help on this topic? Click here
This article has no comments
Show me similar articles
In previous diary notes (Changing the shell and DHCP (again)) I wrote that a symbolic link should be created when building a port.  This is not necessary.  Perhaps it was once necessary because that's what is done in the Compiling ports from CDROM section of the FreeBSD Handbook.
A bit about make
One of the best features of the make process is the fetch process.  If the files it needs cannot be found, make will go and fetch the file for you.  It searches a list of file locations and uses the first location which succeeds.

If you examine /usr/share/mk/bsd.port.mk, you'll find that it modifies the URL search path and adds file:/crdom/ports/distfiles.   This tells the make process to search your CDROM.  If the device is not mounted, the fetch will fail and the search process continues with the next location in the list.

It is because of this search process that the following should be enough to build your port:

# #installer usually leaves /cdrom in fstab
# #which means you don't have to do much to mount it
# mount /cdrom
# cd /usr/ports/foo/bar
# make install


Share
Need more help on this topic? Click here
This article has no comments
Show me similar articles