summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-p2p/fms')
-rw-r--r--net-p2p/fms/Manifest2
-rw-r--r--net-p2p/fms/files/fms38
-rw-r--r--net-p2p/fms/files/fms-use-system-libs2.patch22
-rw-r--r--net-p2p/fms/fms-0.3.73.ebuild71
-rw-r--r--net-p2p/fms/fms-0.3.75.ebuild71
-rw-r--r--net-p2p/fms/metadata.xml13
6 files changed, 217 insertions, 0 deletions
diff --git a/net-p2p/fms/Manifest b/net-p2p/fms/Manifest
new file mode 100644
index 00000000000..1886ec79ae7
--- /dev/null
+++ b/net-p2p/fms/Manifest
@@ -0,0 +1,2 @@
+DIST fms-src-0.3.73.zip 3519550 SHA256 f20985efa71c77c843f7cd16e437414ba2810c5a69d7917456e2a2e6e551a6e5 SHA512 457a6808e85dce8ac3cc31ac465eeb6e271294b6aac9436a12adb21f1dacc5ef8726c558dd6734a7418cff1ce92c172062e0eb5b4642e29a83235cccc9198d2c WHIRLPOOL 8fd8a4b59b003df5b3b91f9d9dde134b3832fb572a772e3129889c56c5c9be10040161cff8fcb1b6183ebe156b9b340bef2481d43519044a8cb54ed0887624a4
+DIST fms-src-0.3.75.zip 3691556 SHA256 1fe5e84aba572143fe95ffb384177e150d5cd4dff2930462b9df24b59c03d85e SHA512 ce5754c0f15c18c0e9692bb840119576ffa9eca05ca38060a0778fc170a614d394ffcc06274bcdc4db5659d176f00e993904a76099382e7eea5685c3a83d3cd8 WHIRLPOOL 405198eff290d8b55e5b5c164fbbd845c086ed76d6d17efa24ab630c109d09b83c8a956b45d6613672b08a19101275a6a8375ba06065e6d9e9b20e1da6c759af
diff --git a/net-p2p/fms/files/fms b/net-p2p/fms/files/fms
new file mode 100644
index 00000000000..8def4b0eba6
--- /dev/null
+++ b/net-p2p/fms/files/fms
@@ -0,0 +1,38 @@
+#!/sbin/runscript
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+# Check for OpenRC/Baselayout 2 - see bug #270646
+is_openrc() {
+ [ -f /lib/librc.so -o -f /etc/init.d/sysfs -o -f /lib/rc/version ]
+}
+
+start() {
+ ebegin "Starting FMS"
+ if is_openrc; then
+ start-stop-daemon -S -u freenet:freenet -d /var/freenet/fms -b -x /usr/bin/fms
+ eend $?
+ else
+ cd /var/freenet/fms
+ su -s /bin/sh -c "fms --daemon" freenet
+ eend $?
+ fi
+}
+
+stop() {
+ ebegin "Stopping FMS"
+ if is_openrc; then
+ start-stop-daemon -K -u freenet:freenet -d /var/freenet/fms /usr/bin/fms
+ eend $?
+ else
+ pkill -u freenet -f "fms --daemon"
+ eend 0
+ fi
+ if [[ $RC_CMD == "restart" ]]; then
+ ebegin "Waiting a few seconds to be sure FMS is ready for restart"
+ sleep 10
+ #give fms time to stop and release the nntp port
+ fi
+}
+
diff --git a/net-p2p/fms/files/fms-use-system-libs2.patch b/net-p2p/fms/files/fms-use-system-libs2.patch
new file mode 100644
index 00000000000..39e62e34179
--- /dev/null
+++ b/net-p2p/fms/files/fms-use-system-libs2.patch
@@ -0,0 +1,22 @@
+--- CMakeLists.txt 2012-03-04 13:01:24.000000000 +0100
++++ CMakeLists.txt.new 2012-03-08 22:14:27.000000000 +0100
+@@ -353,9 +353,16 @@
+ ENDIF(AUDIO_CAPTCHA)
+
+ IF(FROST_SUPPORT)
+- ADD_SUBDIRECTORY(libs/polarssl)
+- TARGET_LINK_LIBRARIES(fms polarssl)
+- INCLUDE_DIRECTORIES(libs/polarssl/include)
++
++ FIND_LIBRARY(POLARSSL_LIBRARY NAMES polarssl libpolarssl)
++
++ IF(POLARSSL_LIBRARY)
++ TARGET_LINK_LIBRARIES(fms ${POLARSSL_LIBRARY})
++ ELSE(POLARSSL_LIBRARY)
++ ADD_SUBDIRECTORY(libs/polarssl)
++ TARGET_LINK_LIBRARIES(fms polarssl)
++ INCLUDE_DIRECTORIES(libs/polarssl/include)
++ ENDIF(POLARSSL_LIBRARY)
+
+ ADD_DEFINITIONS(-DFROST_SUPPORT)
+
diff --git a/net-p2p/fms/fms-0.3.73.ebuild b/net-p2p/fms/fms-0.3.73.ebuild
new file mode 100644
index 00000000000..4db60f324d8
--- /dev/null
+++ b/net-p2p/fms/fms-0.3.73.ebuild
@@ -0,0 +1,71 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit eutils cmake-utils user
+
+DESCRIPTION="A spam-resistant message board application for Freenet"
+HOMEPAGE="http://freenetproject.org/tools.html"
+SRC_URI="mirror://gentoo/${PN}-src-${PV}.zip"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="frost"
+
+RDEPEND="virtual/libiconv
+ frost? ( net-libs/polarssl )
+ >=dev-libs/poco-1.4.3_p1
+ >=dev-db/sqlite-3.6.15"
+DEPEND="${RDEPEND}
+ app-arch/unzip"
+
+S=${WORKDIR}
+
+pkg_setup() {
+ enewgroup freenet
+ enewuser freenet -1 -1 /var/freenet freenet
+}
+
+src_prepare() {
+ edos2unix src/http/pages/showfilepage.cpp
+ epatch "${FILESDIR}"/${PN}-use-system-libs2.patch
+}
+
+src_configure() {
+ local mycmakeargs="-DI_HAVE_READ_THE_README=ON \
+ -DUSE_BUNDLED_SQLITE=OFF \
+ -DDO_CHARSET_CONVERSION=ON \
+ $(cmake-utils_use frost FROST_SUPPORT)"
+ cmake-utils_src_configure
+}
+
+src_install() {
+ insinto /var/freenet/fms
+ dobin "${CMAKE_BUILD_DIR}"/fms || die
+ doins *.htm || die "doinstall failed"
+ doins -r fonts images styles translations || die
+ fperms -R o-rwx /var/freenet/fms/ /usr/bin/fms
+ fowners -R freenet:freenet /var/freenet/fms/ /usr/bin/fms
+ doinitd "${FILESDIR}/fms" || die "installing init.d file failed"
+ dodoc readme.txt || die "installing doc failed"
+}
+
+pkg_postinst() {
+ if ! has_version 'net-p2p/freenet' ; then
+ ewarn "FMS needs a freenet node to up-/download #ssages."
+ ewarn "Please make sure to have a node you can connect to"
+ ewarn "or install net-p2p/freenet to get FMS working."
+ fi
+ elog "By default, the FMS NNTP server will listen on port 1119,"
+ elog "and the web configuration interface will be running at"
+ elog "http://localhost:8080. For more information, read"
+ elog "${ROOT}usr/share/doc/${PF}/readme.txt.bz2"
+ if use frost; then
+ elog " "
+ elog "You need to enable frost on the config page"
+ elog "and restart fms for frost support."
+ fi
+}
diff --git a/net-p2p/fms/fms-0.3.75.ebuild b/net-p2p/fms/fms-0.3.75.ebuild
new file mode 100644
index 00000000000..c3014c21a68
--- /dev/null
+++ b/net-p2p/fms/fms-0.3.75.ebuild
@@ -0,0 +1,71 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit eutils cmake-utils user
+
+DESCRIPTION="A spam-resistant message board application for Freenet"
+HOMEPAGE="http://freenetproject.org/tools.html"
+SRC_URI="mirror://gentoo/${PN}-src-${PV}.zip"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="frost"
+
+RDEPEND="virtual/libiconv
+ frost? ( net-libs/polarssl )
+ >=dev-libs/poco-1.4.3_p1
+ >=dev-db/sqlite-3.6.15"
+DEPEND="${RDEPEND}
+ app-arch/unzip"
+
+S=${WORKDIR}
+
+pkg_setup() {
+ enewgroup freenet
+ enewuser freenet -1 -1 /var/freenet freenet
+}
+
+src_prepare() {
+ edos2unix src/http/pages/showfilepage.cpp
+ epatch "${FILESDIR}"/${PN}-use-system-libs2.patch
+}
+
+src_configure() {
+ local mycmakeargs="-DI_HAVE_READ_THE_README=ON \
+ -DUSE_BUNDLED_SQLITE=OFF \
+ -DDO_CHARSET_CONVERSION=ON \
+ $(cmake-utils_use frost FROST_SUPPORT)"
+ cmake-utils_src_configure
+}
+
+src_install() {
+ insinto /var/freenet/fms
+ dobin "${CMAKE_BUILD_DIR}"/fms || die
+ doins *.htm || die "doinstall failed"
+ doins -r fonts images styles translations || die
+ fperms -R o-rwx /var/freenet/fms/ /usr/bin/fms
+ fowners -R freenet:freenet /var/freenet/fms/ /usr/bin/fms
+ doinitd "${FILESDIR}/fms" || die "installing init.d file failed"
+ dodoc readme.txt || die "installing doc failed"
+}
+
+pkg_postinst() {
+ if ! has_version 'net-p2p/freenet' ; then
+ ewarn "FMS needs a freenet node to up-/download #ssages."
+ ewarn "Please make sure to have a node you can connect to"
+ ewarn "or install net-p2p/freenet to get FMS working."
+ fi
+ elog "By default, the FMS NNTP server will listen on port 1119,"
+ elog "and the web configuration interface will be running at"
+ elog "http://localhost:8080. For more information, read"
+ elog "${ROOT}usr/share/doc/${PF}/readme.txt.bz2"
+ if use frost; then
+ elog " "
+ elog "You need to enable frost on the config page"
+ elog "and restart fms for frost support."
+ fi
+}
diff --git a/net-p2p/fms/metadata.xml b/net-p2p/fms/metadata.xml
new file mode 100644
index 00000000000..6c6e72a6d9f
--- /dev/null
+++ b/net-p2p/fms/metadata.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>tommy@gentoo.org</email>
+ <name>Thomas Sachau (Tommy[D])</name>
+ </maintainer>
+ <herd>net-p2p</herd>
+ <use>
+ <flag name='frost'>Add support for frost boards</flag>
+ </use>
+</pkgmetadata>
+