--- www/osrm-backend/Makefile (nonexistent) +++ www/osrm-backend/Makefile (working copy) @@ -0,0 +1,44 @@ +# $FreeBSD$ + +PORTNAME= osrm-backend +DISTVERSIONPREFIX= v +DISTVERSION= 5.15.2 +CATEGORIES= www + +MAINTAINER= a.andersson.thn@gmail.com +COMMENT= Open Source Routing Machine (Backend) + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE.TXT + +BUILD_DEPENDS= ${LOCALBASE}/lib/libstxxl.a:devel/stxxl +LIB_DEPENDS= libtbb.so:devel/tbb \ + libtbbmalloc.so:devel/tbb \ + libluabind.so:devel/luabind \ + libboost_program_options.so:devel/boost-libs \ + libboost_date_time.so:devel/boost-libs \ + libboost_chrono.so:devel/boost-libs \ + libboost_filesystem.so:devel/boost-libs \ + libboost_iostreams.so:devel/boost-libs \ + libboost_thread.so:devel/boost-libs \ + libboost_system.so:devel/boost-libs \ + libboost_regex.so:devel/boost-libs \ + libexpat.so:textproc/expat2 + +USES= cmake:outsource lua:52 compiler:c++14-lang + +USE_LDCONFIG= yes +OPTIONS_DEFINE= DEBUG + +USE_RC_SUBR= osrm +USERS= osrm +GROUPS= osrm + +USE_GITHUB= yes +GH_ACCOUNT= Project-OSRM + +LUA_VER= 5.2 + +pre-install: + ${MKDIR} ${STAGEDIR}/var/db/osrm-backend +.include --- www/osrm-backend/distinfo (nonexistent) +++ www/osrm-backend/distinfo (working copy) @@ -0,0 +1,3 @@ +TIMESTAMP = 1518251752 +SHA256 (Project-OSRM-osrm-backend-v5.15.2_GH0.tar.gz) = ab966e9b38b4a64d3b43a83ae0b2b9ce4fddc040a230a0f4ed48e2d46ddaf229 +SIZE (Project-OSRM-osrm-backend-v5.15.2_GH0.tar.gz) = 5018331 --- www/osrm-backend/files/osrm.in (nonexistent) +++ www/osrm-backend/files/osrm.in (working copy) @@ -0,0 +1,60 @@ +#!/bin/sh + +# PROVIDE: osrm +# REQUIRE: LOGIN cleanvar +# KEYWORD: shutdown +# +# +# osrm_enable (bool): Set to NO by default. +# Set it to YES to enable osrm-backend. +# osrm_flags (flags): Empty by default +# Adjust it to your needs. +# osrm_file (path): The path to the osrm-file you intend +# to use with osrm. +# osrm_shared_memory (bool): Set to NO by default. +# When enabled it will ignore osrm_file +# and assume osrm-datastore has set up +# the data in shared memory. +# osrm will fail to start if this is +# enbled and osrm-datastore hasnt set +# up the shared memory. + +. /etc/rc.subr + +name="osrm" +rcvar=${name}_enable +load_rc_config $name + +: ${osrm_enable:="NO"} +: ${osrm_user:="osrm"} +: ${osrm_group:="osrm"} +: ${osrm_flags:=""} +: ${osrm_shared_memory:="NO"} +: ${osrm_file:=""} + + + + +pidfile="/var/run/osrm.pid" +procname="/usr/local/bin/osrm-routed" +command=/usr/sbin/daemon +start_precmd="osrm_precmd" + +osrm_precmd() +{ + if checkyesno osrm_shared_memory; then + command_args="-f -c -p ${pidfile} ${procname} --shared-memory=yes ${osrm_flags}" + else + + if [ -f "$osrm_file" ]; then + chown ${osrm_user}:${osrm_group} ${osrm_file} + command_args="-f -c -p ${pidfile} ${procname} ${osrm_flags} ${osrm_file}" + else + err 1 "Osrm file not found or osrm_file variable empty." + fi + fi + install -o $osrm_user -m 644 /dev/null ${pidfile} +} + + +run_rc_command "$1" --- www/osrm-backend/pkg-descr (nonexistent) +++ www/osrm-backend/pkg-descr (working copy) @@ -0,0 +1,3 @@ +This is a port of osrm-backend of the open-streetmap project. + +WWW: http://project-osrm.org/ --- www/osrm-backend/pkg-plist (nonexistent) +++ www/osrm-backend/pkg-plist (working copy) @@ -0,0 +1, @@ +