# Template file for 'boinc' pkgname=boinc version=7.22.0 revision=3 _majorver=${version%.*} build_style=gnu-configure hostmakedepends="automake libtool pkg-config xorgproto shared-mime-info" makedepends="glu-devel libfreeglut-devel libcurl-devel libjpeg-turbo-devel libnotify-devel sqlite-devel libxcb-devel libXmu-devel libXi-devel wxWidgets-gtk3-devel" depends="curl ca-certificates" conf_files="/etc/default/boinc-client" short_desc="Berkely Infrastructure for Network Computing" maintainer="Orphaned " license="LGPL-3.0-or-later" homepage="https://boinc.berkeley.edu/" distfiles="https://github.com/BOINC/boinc/archive/client_release/${_majorver}/${version}.tar.gz>boinc-${version}.tar.gz" checksum=7c7014300cb6e859b6f784f5c76ff2cb96d36ae35d90e03d1e2e59174cb7c927 system_accounts="boinc" boinc_homedir="/var/lib/boinc" boinc_shell="/bin/bash" conflicts="boinc-nox>=0" CXXFLAGS="-Wno-redundant-decls -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" case "$XBPS_TARGET_MACHINE" in armv6l) broken="arm-linux-gnueabihf-g++: error: libwhetvfp.a: No such file or directory" ;; esac pre_configure() { autoreconf -if } do_configure() { if [ -n "$CROSS_BUILD" ]; then # XXX: cross building used to be a lot easier # Set include paths for configure to find dependencies. CFLAGS+=" -I${XBPS_CROSS_BASE}/usr/include/glib-2.0" CFLAGS+=" -I${XBPS_CROSS_BASE}/usr/lib/glib-2.0/include" CXXFLAGS+=" ${CFLAGS}" echo "CFLAGS: $CFLAGS" echo "CXXFLAGS: $CXXFLAGS" export LIBNOTIFY_CFLAGS="${CFLAGS}" export LIBNOTIFY_LIBS="-L${XBPS_CROSS_BASE}/usr/lib -lnotify" fi mkdir /tmp/x11 mv * /tmp/x11 mv /tmp/x11 . mkdir nox cp -ar x11/* nox cd ${wrksrc}/x11 PKG_CONFIG=pkg-config \ PKG_CONFIG_PATH=${XBPS_CROSS_BASE}/usr/lib/pkgconfig \ LDFLAGS="${LDFLAGS} -lX11" \ ./configure \ ${configure_args} \ --enable-libraries \ --enable-unicode \ --enable-shared \ --enable-static \ --enable-dynamic-client-linkage \ --enable-client \ --enable-manager \ --disable-server \ --with-ssl=${XBPS_CROSS_BASE}/usr \ --with-x=${XBPS_CROSS_BASE}/usr \ --with-wx-config=${XBPS_CROSS_BASE}/usr/bin/wx-config-gtk3 \ --with-wx-prefix=${XBPS_CROSS_BASE}/usr cd ${wrksrc}/nox PKG_CONFIG=pkg-config \ PKG_CONFIG_PATH=${XBPS_CROSS_BASE}/usr/lib/pkgconfig \ ./configure \ ${configure_args} \ --enable-libraries \ --enable-unicode \ --enable-shared \ --enable-static \ --enable-dynamic-client-linkage \ --enable-client \ --disable-manager \ --disable-server \ --disable-server \ --with-ssl=${XBPS_CROSS_BASE}/usr \ --without-x \ --without-wxdir } do_build() { cd ${wrksrc}/x11 make ${makejobs} cd ${wrksrc}/nox make ${makejobs} } do_install() { cd ${wrksrc}/x11 make ${makejobs} DESTDIR="${DESTDIR}" install if [ -f "${DESTDIR}/etc/boinc-client.conf" ]; then vmkdir etc/default mv "${DESTDIR}"/etc/boinc-client.conf \ "${DESTDIR}"/etc/default/boinc-client fi # Bash completion vinstall ${FILESDIR}/boinc.bash 644 usr/share/bash-completion/completions boinc # Desktop vmkdir usr/share/applications vinstall ${FILESDIR}/boinc.desktop 644 usr/share/applications for size in 16 24 32 64 128 256; do vinstall ${FILESDIR}/boinc${size}.png 644 \ usr/share/icons/hicolor/${size}x${size}/apps \ boinc.png done vinstall ${FILESDIR}/boinc32.png 644 usr/share/pixmaps boinc.png vsv boinc } boinc-devel_package() { depends="${sourcepkg}>=${version}_${revision}" short_desc+=" - development files" pkg_install() { vmove usr/include vmove "usr/lib/*.a" vmove "usr/lib/*.so" } } boinc-nox_package() { short_desc+=" - no X" conflicts="boinc>=0" system_accounts="boinc" boinc_homedir="/var/lib/boinc" boinc_shell="/bin/bash" pkg_install() { cd ${wrksrc}/nox make ${makejobs} DESTDIR=${PKGDESTDIR} install if [ -f "${PKGDESTDIR}/etc/boinc-client.conf" ]; then vmkdir etc/default mv "${PKGDESTDIR}"/etc/boinc-client.conf \ "${PKGDESTDIR}"/etc/default/boinc-client fi # no devel package - no includes, *.a and *.so rm -rf ${PKGDESTDIR}/usr/include rm -f ${PKGDESTDIR}/usr/lib/*.a rm -f ${PKGDESTDIR}/usr/lib/*.so # Bash completion vinstall ${FILESDIR}/boinc.bash 644 usr/share/bash-completion/completions boinc vsv boinc } }