1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-01 01:17:02 +00:00
freebsd-ports/misc/nut/Makefile
Niclas Zeising 39fc32e828 The FreeBSD x11@ and graphics team proudly presents
a zeising, kwm production, with help from dumbbell, bdrewery:

NEW XORG ON FREEBSD 9-STABLE AND 10-STABLE

This update switches over to use the new xorg stack by default on FreeBSD 9
and 10 stable, on osversions where vt(9) is available.
It is still possible to use the old stack by specifying WITHOUT_NEW_XORG in
/etc/make.conf .
FreeBSD 8-STABLE and released versions of FreeBSD still use
the old version.
A package repository with binary packages for new xorg will
be available soon.

This patch also contains updates of libxcb and related ports, pixman, as well
as some drivers and utilities.

Bump portrevisions for xf86-* ports, as well as virtualbox-ose-additions due
to xserver version change.

Apart from these updates, the way shared libraries are handled has been
changed for all xorg ports, as well as libxml2 and freetype, which means
ltverhack is gone and as a consequence shared libraries have been bumped.
The plan is that this change will make library bumps less likely in the
future.
All affected ports have had their portrevisions bumped as a consequence of
this.

Fix some issues where WITH_NEW_XORG weren't detected properly on CURRENT.

Update instructions, hardware support, and more notes can be found on
https://wiki.freebsd.org/Graphics

Thanks to:	all testers, bdrewery and the FreeBSD x11@ team
exp-run by:	bdrewery [1]
PR:		ports/187602 [1]
Approved by:	portmgr (bdrewery), core (jhb)
2014-04-16 18:28:47 +00:00

76 lines
2.0 KiB
Makefile

# Created by: Kirill Ponomarew <ponomarew@oberon.net>
# $FreeBSD$
PORTNAME= nut
PORTVERSION= 18.4
PORTREVISION= 2
CATEGORIES= misc
MASTER_SITES= SF
PKGNAMEPREFIX= health-
MAINTAINER= ports@FreeBSD.org
COMMENT= Nutrition software to record what you eat
LICENSE= GPLv2 # (or later)
OPTIONS_DEFINE= FLTK DOCS
FLTK_DESC= Install FLTK GUI
USE_GMAKE= yes
DOCSDIR= ${PREFIX}/share/doc/${UNIQUENAME}
MAN1= ${PORTNAME}.1
PORTDOCS= CREDITS README nut.html
PLIST_FILES= bin/${PORTNAME} %%DATADIR%%/FOOD_DES.txt \
%%DATADIR%%/NUT_DATA.txt %%DATADIR%%/WEIGHT.lib \
%%DATADIR%%/WEIGHT.txt %%DATADIR%%/sr25.nut
PLIST_DIRS= %%DATADIR%%
NO_STAGE= yes
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MFLTK}
LIB_DEPENDS+= pthread-stubs:${PORTSDIR}/devel/libpthread-stubs \
libfreetype.so:${PORTSDIR}/print/freetype2 \
expat:${PORTSDIR}/textproc/expat2 \
fontconfig:${PORTSDIR}/x11-fonts/fontconfig \
fltk_images:${PORTSDIR}/x11-toolkits/fltk
USE_XORG+= x11 xau xcb xdmcp xext xft xinerama xrender
MAKE_ENV+= HAVE_FLTK=1 FLTK_NUT="fltk/Nut"
PLIST_FILES+= bin/Nut
DESKTOP_ENTRIES="Nut" "${COMMENT}" "" "Nut" \
"Science;Biology;MedicalSoftware;" "false"
.else
MAKE_ENV+= HAVE_FLTK=0 FLTK_NUT=""
.endif
post-patch:
@${FIND} ${WRKSRC} -name "Makefile" | ${XARGS} ${REINPLACE_CMD} -e \
's|$$(prefix)/lib/nut|${DATADIR}| ; \
s|^HAVE_FLTK|#HAVE_FLTK| ; \
s|^FLTK_NUT|#FLTK_NUT| ; \
s|^CC =|CC ?=| ; \
s|^CXX =|CXX ?=| ; \
s|^CFLAGS :=|CFLAGS +=| ; \
s|-ansi -pedantic|| ; \
s|$$(OPT)|| ; \
s|ldstaticflags|ldflags| '
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin
${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${MANPREFIX}/man/man1
.if ${PORT_OPTIONS:MFLTK}
${INSTALL_PROGRAM} ${WRKSRC}/fltk/Nut ${PREFIX}/bin
.endif
@${MKDIR} ${DATADIR}
@(cd ${WRKSRC}/raw.data && ${COPYTREE_SHARE} . ${DATADIR})
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${DOCSDIR}
.for file in ${PORTDOCS}
${INSTALL_DATA} ${WRKSRC}/${file} ${DOCSDIR}
.endfor
.endif
.include <bsd.port.mk>