1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-21 04:06:46 +00:00

- OPTION'fy.

- Add an option for enable mmap support.

Approved by:	freebsd__at__luna.afraid.org (maintainer)
This commit is contained in:
Hajimu UMEMOTO 2006-06-16 20:16:24 +00:00
parent 1b41a788a0
commit 5e7831b31d
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=165597
2 changed files with 14 additions and 10 deletions

View File

@ -18,6 +18,9 @@ MAN4= pwc.4
WRKSRC= ${WRKDIR}/${PORTNAME}
NO_PACKAGE= should be recompiled for a particular FreeBSD kernel
OPTIONS= PROGRAMS "Build the programs" on \
MMAP "Enable mmap support (MAY CRASH YOUR SYSTEM)" off
.include <bsd.port.pre.mk>
.if ${OSVERSION} < 504000
@ -28,8 +31,13 @@ IGNORE= requires FreeBSD 5.4 or superior
IGNORE= requires kernel source files
.endif
.if defined(WITH_MMAP)
ALL_TARGET= mmap
.else
ALL_TARGET= all
.endif
.if !defined(WITHOUT_PROGRAMS)
ALL_TARGET= all pwcview
ALL_TARGET+= pwcview
PROGRAMS= pwcview
LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg
MAN1= pwcview.1
@ -39,15 +47,6 @@ PLIST_SUB+= PROGRAMS=""
PLIST_SUB+= PROGRAMS="@comment "
.endif
pre-everything::
.if !defined(WITHOUT_PROGRAMS)
@${ECHO_MSG} "=================================================="
@${ECHO_MSG} "You may specify the following on the command line:"
@${ECHO_MSG} ""
@${ECHO_MSG} "WITHOUT_PROGRAMS=yes to only build the driver "
@${ECHO_MSG} "=================================================="
.endif
post-patch:
.if !defined(WITHOUT_PROGRAMS)
@${REINPLACE_CMD} -e 's|sdl11-config|${SDL_CONFIG}|g' ${WRKSRC}/Makefile

View File

@ -14,4 +14,9 @@ To load the kernel module at boot, add the following line to
pwc_load="YES"
CAUTION: If you enabled mmap support in the driver, beware that
unplugging your webcam while it is in use may crash your system. So
if you enabled mmap support, always remember to first exit the
application that is using the webcam before unplugging the webcam.
===============================================================================