1 |
# $MidnightBSD$ |
2 |
|
3 |
PORTNAME= boinc-client |
4 |
PORTVERSION= 7.2.33 |
5 |
CATEGORIES= net |
6 |
MASTER_SITES= FREEBSD_LOCAL/rene |
7 |
|
8 |
MAINTAINER= ports@MidnightBSD.org |
9 |
COMMENT= Berkeley Open Infrastructure for Network Computing client |
10 |
|
11 |
LICENSE= gpl2 |
12 |
|
13 |
INSTALL_TARGET= install-strip |
14 |
USES= autoreconf gmake libtool pkgconfig tar:xz |
15 |
GNU_CONFIGURE= yes |
16 |
USE_LDCONFIG= yes |
17 |
USE_DOS2UNIX= yes |
18 |
DOS2UNIX_GLOB= *.xpm |
19 |
|
20 |
USERS= boinc |
21 |
GROUPS= boinc |
22 |
|
23 |
BOINC_CLIENT_USER?= boinc |
24 |
BOINC_CLIENT_GROUP?= boinc |
25 |
BOINC_CLIENT_HOME?= /var/db/boinc |
26 |
|
27 |
SUB_FILES= pkg-install |
28 |
SUB_LIST= BOINC_CLIENT_HOME="${BOINC_CLIENT_HOME}" \ |
29 |
BOINC_CLIENT_USER="${BOINC_CLIENT_USER}" \ |
30 |
BOINC_CLIENT_GROUP="${BOINC_CLIENT_GROUP}" \ |
31 |
PREFIX="${PREFIX}" LOCALBASE="${LOCALBASE}" |
32 |
|
33 |
CONFIGURE_ARGS= --disable-server |
34 |
CONFIGURE_ENV= OBJCXX="${CXX}" |
35 |
CPPFLAGS+= -I${LOCALBASE}/include |
36 |
LDFLAGS+= -L${LOCALBASE}/lib |
37 |
|
38 |
OPTIONS_DEFINE= CLIENT MANAGER NLS X11 LINUX USER SKINS |
39 |
OPTIONS_DEFAULT= CLIENT MANAGER X11 USER |
40 |
OPTIONS_GROUP= SCRIPT |
41 |
OPTIONS_GROUP_SCRIPT= NO_GUI_RPC NO_NET_INFO |
42 |
CLIENT_DESC= Build BOINC client |
43 |
MANAGER_DESC= Build BOINC manager GUI |
44 |
X11_DESC= Build graphics API |
45 |
LINUX_DESC= Accept Linux science applications |
46 |
USER_DESC= Create/check BOINC client user and directory |
47 |
SKINS_DESC= Install more skins for BOINC manager |
48 |
SCRIPT_DESC= Command line options in script |
49 |
NO_GUI_RPC_DESC= Disable GUI RPC and socket (breaks boinc_curses) |
50 |
NO_NET_INFO_DESC= Do not send host address and name to servers |
51 |
|
52 |
OPTIONS_SUB= yes |
53 |
|
54 |
MANAGER_USES= iconv |
55 |
MANAGER_LIB_DEPENDS= libnotify.so:${PORTSDIR}/devel/libnotify |
56 |
MANAGER_CONFIGURE_ON= --with-sqlite3-prefix=/usr |
57 |
MANAGER_CONFIGURE_OFF= --with-wx-config=false --without-x |
58 |
MANAGER_CONFIGURE_ENABLE=manager |
59 |
MANAGER_USE= XORG=x11,xext,xscrnsaver WX=2.8 |
60 |
|
61 |
CLIENT_CONFIGURE_ENABLE=client |
62 |
CLIENT_LIB_DEPENDS= libcurl.so:${PORTSDIR}/ftp/curl |
63 |
CLIENT_RUN_DEPENDS= ${LOCALBASE}/share/certs/ca-root-nss.crt:${PORTSDIR}/security/ca_root_nss |
64 |
CLIENT_USE= RC_SUBR=boinc-client |
65 |
|
66 |
LINUX_CONFIGURE_ON= --with-boinc-alt-platform=i686-pc-linux-gnu |
67 |
LINUX_USE= LINUX=yes |
68 |
|
69 |
X11_LIB_DEPENDS= libjpeg.so:${PORTSDIR}/graphics/jpeg |
70 |
X11_USE= GL=glut XORG=xmu,xi |
71 |
X11_CONFIGURE_OFF= ax_cv_check_glut_libglut=no |
72 |
|
73 |
.include <bsd.mport.options.mk> |
74 |
|
75 |
.if ${PORT_OPTIONS:MMANAGER} |
76 |
WX_CONF_ARGS= absolute |
77 |
WX_UNICODE= yes |
78 |
. if ${OSVERSION} < 4016 |
79 |
CPPFLAGS+= -DNO_PER_THREAD_LOCALE |
80 |
. endif |
81 |
SUB_LIST+= OPTION_MANAGER="true" |
82 |
.else |
83 |
SUB_LIST+= OPTION_MANAGER="" |
84 |
.endif |
85 |
|
86 |
.if ${PORT_OPTIONS:MCLIENT} |
87 |
SUB_LIST+= OPTION_NO_GUI_RPC=${PORT_OPTIONS:MNO_GUI_RPC:S/^NO_GUI_RPC$/--no_gui_rpc/} \ |
88 |
OPTION_NO_NET_INFO=${PORT_OPTIONS:MNO_NET_INFO:S/^NO_NET_INFO$/--suppress_net_info/} |
89 |
.endif |
90 |
|
91 |
.if ${PORT_OPTIONS:MUSER} |
92 |
SUB_LIST+= OPTION_USER="true" |
93 |
.else |
94 |
SUB_LIST+= OPTION_USER="" |
95 |
.endif |
96 |
|
97 |
post-extract: dos2unix |
98 |
|
99 |
post-patch: |
100 |
@${REINPLACE_CMD} -e 's|@PREFIX@|${PREFIX}|' \ |
101 |
${WRKSRC}/client/hostinfo_unix.cpp |
102 |
@${REINPLACE_CMD} -e 's|client/scripts||' ${WRKSRC}/Makefile.am |
103 |
@${REINPLACE_CMD} -e 's|$$$$mydir/$$$$ldir|&/LC_MESSAGES|' \ |
104 |
${WRKSRC}/locale/Makefile.am |
105 |
# avoid build conflict with archivers/libzip |
106 |
@${MV} ${WRKSRC}/zip/unzip/zip.h ${WRKSRC}/zip/unzip/boinczip.h |
107 |
@${MV} ${WRKSRC}/zip/zip/zip.h ${WRKSRC}/zip/zip/boinczip.h |
108 |
@${REINPLACE_CMD} -e 's|zip/zip.h|zip/boinczip.h|' \ |
109 |
${WRKSRC}/zip/boinc_zip.cpp |
110 |
@${REINPLACE_CMD} -e 's|"zip.h"|"boinczip.h"|' \ |
111 |
${WRKSRC}/zip/unzip/crc32.c ${WRKSRC}/zip/unzip/ttyio.c \ |
112 |
${WRKSRC}/zip/zip/deflate.c ${WRKSRC}/zip/zip/trees.c \ |
113 |
${WRKSRC}/zip/zip/unix/z_unix.c ${WRKSRC}/zip/zip/util.c \ |
114 |
${WRKSRC}/zip/zip/z_fileio.c ${WRKSRC}/zip/zip/z_globals.c \ |
115 |
${WRKSRC}/zip/zip/zip.c ${WRKSRC}/zip/zip/zipfile.c \ |
116 |
${WRKSRC}/zip/zip/zipup.c |
117 |
|
118 |
post-install: |
119 |
.if ${PORT_OPTIONS:MMANAGER} || ${PORT_OPTIONS:MX11} |
120 |
${MKDIR} ${STAGEDIR}${PREFIX}/share/boinc |
121 |
.endif |
122 |
.if ${PORT_OPTIONS:MMANAGER} |
123 |
. for name in 16 32 48 |
124 |
${INSTALL_DATA} ${WRKSRC}/clientgui/res/boincmgr.${name}x${name}.png \ |
125 |
${STAGEDIR}${PREFIX}/share/pixmaps |
126 |
. endfor |
127 |
. if ${PORT_OPTIONS:MSKINS} |
128 |
(cd ${WRKSRC}/clientgui && \ |
129 |
${COPYTREE_SHARE} skins ${STAGEDIR}${PREFIX}/share/boinc/ ) |
130 |
. else |
131 |
${MKDIR} ${STAGEDIR}${PREFIX}/share/boinc/skins |
132 |
(cd ${WRKSRC}/clientgui/skins && \ |
133 |
${COPYTREE_SHARE} Default ${STAGEDIR}${PREFIX}/share/boinc/skins/ ) |
134 |
. endif |
135 |
.endif |
136 |
. for name in config.h project_specific_defines.h api/reduce.h \ |
137 |
lib/opencl_boinc.h lib/shmem.h lib/std_fixes.h |
138 |
${INSTALL_DATA} ${WRKSRC}/${name} ${STAGEDIR}${PREFIX}/include/boinc |
139 |
. endfor |
140 |
.if ${PORT_OPTIONS:MX11} |
141 |
. for name in api/boinc_gl.h api/graphics_api.h api/graphics_data.h \ |
142 |
api/ttfont.h |
143 |
${INSTALL_DATA} ${WRKSRC}/${name} ${STAGEDIR}${PREFIX}/include/boinc |
144 |
. endfor |
145 |
${MKDIR} ${STAGEDIR}${PREFIX}/share/boinc/ttf |
146 |
(cd ${WRKSRC}/api/ttf/liberation-fonts-ttf-2.00.0 && \ |
147 |
${COPYTREE_SHARE} \*.ttf ${STAGEDIR}${PREFIX}/share/boinc/ttf/ ) |
148 |
.endif |
149 |
|
150 |
.include <bsd.port.mk> |