Question about optional setting of symbolic links

Jonathan Weiss tomonage2 at gmx.de
Fri Jan 7 07:14:43 PST 2005


Hi folks,


I'm working on a port of foomatic-filters and I want to optionaly set up a
symbolic link if CUPS-support is wanted (in order to register foomatic-rip
as a filter for cups).

How do I do this?

I looked through the porters handbook and could not find something to
symbolic links.

I want to do something like this:

#.if defined(WITH_CUPS)
#ln -s /usr/local/bin/foomatic-rip
/usr/local/libexec/cups/filter/foomatic-rip
#.endif

How do I remove this link later?



My Makefile looks like this:
----------------------------------
# New ports collection makefile for:    foomatic-filters
# Date created:                4 January 2005
# Whom:                    Jonathan Weiss <tomonage2 at gmx.de
#
# $FreeBSD$
#

PORTNAME=    foomatic-filters
PORTVERSION=    3.0.2
CATEGORIES=    print
MASTER_SITES=    http://www.linuxprinting.org/download/foomatic/

MAINTAINER=    tomonage2 at gmx.de
COMMENT=    A system for integrating printer drivers with common spoolers


MAN1=        foomatic-rip.1 foomatic-gswrapper.1
PLIST_FILES=    bin/foomatic-rip etc/filter.conf.example
bin/foomatic-gswrapper

GNU_CONFIGURE=        yes
USE_PERL5=        yes

CONFIGURE_ARGS+=        --prefix=${PREFIX} \
            --sysconfdir=${PREFIX}/etc


do-install:
    ${INSTALL_SCRIPT} ${WRKSRC}/foomatic-rip ${PREFIX}/bin
    ${INSTALL_SCRIPT} ${WRKSRC}/foomatic-gswrapper ${PREFIX}/bin
    ${INSTALL_DATA} ${WRKSRC}/filter.conf ${PREFIX}/etc/filter.conf.example
    ${INSTALL_MAN} ${WRKSRC}/foomatic-rip.1 ${PREFIX}/man/man1
    ${INSTALL_MAN} ${WRKSRC}/foomatic-gswrapper.1 ${PREFIX}/man/man1


.include <bsd.port.mk>
------------------------------------

Thanks,
Jonathan





More information about the freebsd-ports mailing list