blob: 3a1e37304858024669ea60232a0fc1655ab6d9d9 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
# New ports collection makefile for: GUI to Direct Connect Text Client
# Date created: Thu Nov 22 00:34:48 BRST 2001
# Whom: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME= dctc
PORTVERSION= 0.65
PORTREVISION= 1
CATEGORIES= net gnome
MASTER_SITES= http://unixpages.org/distfiles/ \
http://ac2i.tzo.com/dctc/
PKGNAMESUFFIX= -gui
DISTNAME= dc_gui-${PORTVERSION}
MAINTAINER= lioux@FreeBSD.org
BUILD_DEPENDS= dctc:${PORTSDIR}/net/dctc
LIB_DEPENDS= db4.0:${PORTSDIR}/databases/db4 \
intl.4:${PORTSDIR}/devel/gettext
USE_X_PREFIX= yes
USE_GNOMENG= yes
USE_GNOME= gnomehack gnomelibs gnomeprefix
USE_XLIB= yes
USE_REINPLACE= yes
GNU_CONFIGURE= yes
USE_GMAKE= yes
CONFIGURE_ARGS= --with-gnome=${X11BASE} \
--with-gtk-prefix=${LOCALBASE} \
--enable-manual-db-detect \
--with-libiconv-prefix=${LOCALBASE}
ADDITIONAL_SRCS= sig_chld.c
#
DOC_FILES= COPYING ChangeLog README TODO
post-extract:
.for file in ${ADDITIONAL_SRCS}
@${CP} ${FILESDIR}/${file} ${WRKSRC}/src
.endfor
post-patch:
@${FIND} ${WRKSRC} -type f | ${XARGS} -n 10 -x ${REINPLACE_CMD} -E -e \
's|ldb-4.0|ldb4|; \
s|<(db.h>)|<db4/\1|'
@${REINPLACE_CMD} -E -e 's|(hublist)|dc_\1|' \
${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
@${REINPLACE_CMD} -E -e \
's|(hublist)(.+argv)|dc_\1\2|' \
${WRKSRC}/src/init_fnc.c
# XXX - revise at every port update
@${REINPLACE_CMD} -e "s|%'|%|g" ${WRKSRC}/src/*.c
# @${REINPLACE_CMD} -E -e \
# 's|%lf|%f|; \
# s|(%\.[[:digit:]])lf|\1f|' \
# ${WRKSRC}/src/*.c
# clean up so as to not break installation
@${FIND} ${WRKSRC} -type f \
-name "*.bak" \
| ${XARGS} -n 10 -x ${RM}
# add sigchld handler
.for file in ${ADDITIONAL_SRCS}
@${REINPLACE_CMD} -E -e \
's|^(dc_gui_SOURCES.+)$$|\1 ${file}|; \
s|^(dc_gui_OBJECTS[^\\]+)(\\*)$$|\1 ${file:S/.c$/.o/} \2|' \
${WRKSRC}/src/Makefile.in
.endfor
post-configure:
@${ECHO_CMD} '#ifndef MSG_NOSIGNAL' >> ${CONFIGURE_WRKSRC}/config.h
@${ECHO_CMD} '# define MSG_NOSIGNAL 0' >> ${CONFIGURE_WRKSRC}/config.h
@${ECHO_CMD} '#endif' >> ${CONFIGURE_WRKSRC}/config.h
@${ECHO_CMD} '#include <sys/param.h>' >> ${CONFIGURE_WRKSRC}/config.h
@${ECHO_CMD} '#ifndef SEMVMX' >> ${WRKSRC}/config.h
@${ECHO_CMD} '#define SEMVMX 32767' >> ${WRKSRC}/config.h
@${ECHO_CMD} '#endif' >> ${WRKSRC}/config.h
# disable GNU auto* tools
@${FIND} ${WRKSRC} -type f -name "Makefile" | ${XARGS} \
-n 10 ${REINPLACE_CMD} -E -e \
's! (autoconf|autoheader|automake|aclocal)$$! ${TRUE}!'
post-install:
.ifndef(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}${PKGNAMESUFFIX}
.for file in ${DOC_FILES}
@${INSTALL_DATA} ${WRKSRC}/${file} ${DOCSDIR}${PKGNAMESUFFIX}
.endfor
.endif
.include <bsd.port.mk>
|