4ede5e9b24
The following ports will not build with a binutils 2.22+ linker built with standard options. This has been obvious with DPorts, but difficult to see on FreeBSD. However, setting the ports compiler as a recent gcc (e.g lang/gcc48) is an excellent way to detect the unspecified but needed libraries as these recent GCC compilers use the latest binutils linkers. These patches were tested on FreeBSD 8.4 and DragonFly 3.5
78 lines
2.4 KiB
Makefile
78 lines
2.4 KiB
Makefile
# Created by: Ion-Mihai "IOnut" Tetcu <itetcu@people.tecnik93.com>
|
|
# $FreeBSD$
|
|
|
|
PORTNAME= dixit
|
|
PORTVERSION= 11.11
|
|
PORTREVISION= 1
|
|
CATEGORIES= textproc
|
|
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTVERSION} \
|
|
SF/${PORTNAME}/${PORTNAME}_qdb:db \
|
|
LOCAL/bdrewery/${PORTNAME}/ \
|
|
LOCAL/bdrewery/${PORTNAME}:db
|
|
DISTFILES= ${PORTNAME}-${PORTVERSION}.${QT_VER}.tgz \
|
|
${_DB_D}:db
|
|
EXTRACT_ONLY= ${PORTNAME}-${PORTVERSION}.${QT_VER}.tgz
|
|
|
|
MAINTAINER= ports@FreeBSD.org
|
|
COMMENT= Romanian dictionaries databases and query application
|
|
|
|
LICENSE= GPLv3 # (or later)
|
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}.${QT_VER}
|
|
|
|
USE_QT4= corelib gui network moc_build qmake_build rcc_build
|
|
HAS_CONFIGURE= yes
|
|
QMAKEFLAGS= QMAKE_LFLAGS="-lz"
|
|
|
|
PLIST_SUB= _DB=${_DB} DB_DIR=${DB_DIR} _DB_F=${_DB_F}
|
|
|
|
QT_VER= 4
|
|
|
|
DB_DIR?= /var/db/dixit
|
|
DB_OWNER?= root
|
|
DB_GROUP?= wheel
|
|
DB_MODE?= 0664
|
|
# DB_DATE is the time of the file in the zip archive, not the time of the last
|
|
# update of the database (which is a little earlier, but TZ makes it appear to
|
|
# be later), but it's all we can do in a makefile.
|
|
DB_DATE=201204010000
|
|
_DB_D= ${PORTNAME}.qdb.tar.bz2
|
|
_DB_F= ${PORTNAME}.qdb
|
|
_DB= ${DB_DIR}/${_DB_F}
|
|
|
|
NO_STAGE= yes
|
|
pre-everything::
|
|
@${ECHO_MSG}
|
|
@${ECHO_MSG} "Your dictionary database directory is:"
|
|
@${ECHO_MSG} "DB_DIR=${DB_DIR} (default /var/db/dixit)"
|
|
@${ECHO_MSG} "You need about 65MB for the dictionary db."
|
|
@${ECHO_MSG}
|
|
@${ECHO_MSG} "You can allow all users to update (but potentially also delete"
|
|
@${ECHO_MSG} "or alter) the dictionaries database by setting DB_MODE=0666"
|
|
@${ECHO_MSG} "DB_OWNER=${DB_OWNER} (default: root)"
|
|
@${ECHO_MSG} "DB_GROUP=${DB_GROUP} (default: wheel)"
|
|
@${ECHO_MSG} "DB_MODE=${DB_MODE} (default: 0664)"
|
|
@${ECHO_MSG}
|
|
|
|
post-patch:
|
|
@${REINPLACE_CMD} -e \
|
|
's|-O3||' ${WRKSRC}/${PORTNAME}-${PORTVERSION}.${QT_VER}.pro
|
|
@${REINPLACE_CMD} -e \
|
|
's|dixit.qdb|${_DB}|' ${WRKSRC}/src/dixit.h
|
|
|
|
do-configure:
|
|
(cd ${WRKSRC} && ${SETENV} ${CONFIGURE_ENV} ${QMAKE} ${QMAKEFLAGS})
|
|
|
|
do-install:
|
|
(cd ${WRKSRC} && ${INSTALL_PROGRAM} ${PORTNAME} ${PREFIX}/bin)
|
|
@${TOUCH} -t ${DB_DATE} ${WRKSRC}/${_DB_F}
|
|
@${ECHO_MSG} " ===> Installing database ... .. ."
|
|
@if [ ! -e "${_DB}" -o "${_DB}" -ot "${WRKSRC}/${_DB_F}" ]; \
|
|
then ${TAR} -C ${DB_DIR:S/${PORTNAME}//} -xf ${DISTDIR}/${_DB_D} && \
|
|
${ECHO_MSG} " ===> ... Done."; \
|
|
else ${ECHO_MSG} " ===> Exisitng database is newer, skiping";\
|
|
fi
|
|
@${CHOWN} ${DB_OWNER}:${DB_GROUP} ${_DB}
|
|
@${CHMOD} ${DB_MODE} ${_DB}
|
|
|
|
.include <bsd.port.mk>
|