@ -1,72 +0,0 @@ | |||
# | |||
# Copyright (C) 2015 OpenWrt.org | |||
# | |||
# This is free software, licensed under the GNU General Public License v2. | |||
# See /LICENSE for more information. | |||
# | |||
include $(TOPDIR)/rules.mk | |||
PKG_NAME:=fossil | |||
PKG_VERSION:=1.34 | |||
PKG_RELEASE:=2 | |||
PKG_LICENSE:=BSD-2-Clause | |||
PKG_MAINTAINER:=Luka Perkov <luka@openwrt.org> | |||
PKG_SOURCE:=$(PKG_NAME)-src-$(PKG_VERSION).tar.gz | |||
PKG_SOURCE_URL:=https://www.fossil-scm.org/index.html/uv/download | |||
PKG_HASH:=53a6b83e878feced9ac7705f87e5b6ea82727314e3e19202ae1c46c7e4dba49f | |||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-src-$(PKG_VERSION) | |||
PKG_INSTALL:=1 | |||
PKG_BUILD_PARALLEL:=1 | |||
include $(INCLUDE_DIR)/package.mk | |||
define Package/fossil | |||
SECTION:=net | |||
CATEGORY:=Network | |||
SUBMENU:=Version Control Systems | |||
TITLE:=Simple distributed software configuration management | |||
URL:=http://www.fossil-scm.org | |||
DEPENDS:=+zlib | |||
endef | |||
define Package/fossil/description | |||
Fossil is a distributed version control system, bug tracking system | |||
and wiki software server for use in software development. | |||
endef | |||
MAKE_FLAGS := \ | |||
TCC="$(TARGET_CC)" \ | |||
CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include -DFOSSIL_ENABLE_JSON" \ | |||
LDFLAGS="$(TARGET_LDFLAGS) -Wl,-rpath=$(TOOLCHAIN_DIR)/lib -L$(STAGING_DIR)/lib -L$(STAGING_DIR)/usr/lib -lm" \ | |||
define Build/Configure | |||
endef | |||
define Build/Compile | |||
$(call Build/Compile/Default, \ | |||
-f Makefile.classic $(MAKE_FLAGS) all \ | |||
) | |||
endef | |||
define Build/Install | |||
endef | |||
define Package/fossil/conffiles | |||
/etc/config/fossil | |||
endef | |||
define Package/fossil/install | |||
$(INSTALL_DIR) $(1)/usr/bin | |||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_NAME) $(1)/usr/bin/ | |||
$(INSTALL_DIR) $(1)/etc/init.d | |||
$(INSTALL_BIN) ./files/fossil.init $(1)/etc/init.d/fossil | |||
$(INSTALL_DIR) $(1)/etc/config | |||
$(INSTALL_CONF) ./files/fossil.config $(1)/etc/config/fossil | |||
endef | |||
$(eval $(call BuildPackage,fossil)) |
@ -1,5 +0,0 @@ | |||
config server 'dummy' | |||
option repository '/tmp/fossil/dummy' | |||
option port 8008 | |||
option localhost 0 | |||
option create 1 |
@ -1,54 +0,0 @@ | |||
#!/bin/sh /etc/rc.common | |||
# Copyright (C) 2015 OpenWrt.org | |||
START=90 | |||
USE_PROCD=1 | |||
start_instance() { | |||
local cfg="$1" | |||
config_get repository "$cfg" repository | |||
if [ -z "$repository" ]; then | |||
echo "repository is not defined in $1, skipping" | |||
return | |||
fi | |||
config_get_bool create "$cfg" create 0 | |||
if [ "$create" -eq 0 -a ! -f "$repository" ]; then | |||
echo "in $1 create option is '$create' and repository '$repository' is not a regular file, skipping" | |||
return | |||
fi | |||
if [ "$create" -eq 1 -a ! -d `dirname $repository` ]; then | |||
mkdir -p `dirname $repository` | |||
if [ "$?" -ne 0 ]; then | |||
echo "could not create directory, skipping" | |||
return | |||
fi | |||
fi | |||
config_get port "$cfg" port "" | |||
if [ -z "$port" ]; then | |||
echo "port is not defined in $1, skipping" | |||
return | |||
fi | |||
config_get_bool debug "$cfg" debug 0 | |||
config_get_bool localhost "$cfg" localhost 1 | |||
config_get_bool scgi "$cfg" scgi 0 | |||
procd_open_instance | |||
procd_set_param command /usr/bin/fossil server "$repository" --port $port | |||
[ "$debug" -eq 1 ] && procd_append_param command --th-trace | |||
[ "$create" -eq 1 ] && procd_append_param command --user root --create | |||
[ "$localhost" -eq 1 ] && procd_append_param command --localhost | |||
[ "$scgi" -eq 1 ] && procd_append_param command --scgi | |||
procd_set_param respawn | |||
procd_close_instance | |||
} | |||
start_service() { | |||
config_load 'fossil' | |||
config_foreach start_instance 'server' | |||
} |
@ -1,22 +0,0 @@ | |||
--- a/Makefile.classic | |||
+++ b/Makefile.classic | |||
@@ -41,9 +41,6 @@ | |||
# FOSSIL_ENABLE_MINIZ = 1 | |||
# TCC += -DFOSSIL_ENABLE_MINIZ | |||
-# To add support for HTTPS | |||
-TCC += -DFOSSIL_ENABLE_SSL | |||
- | |||
#### We sometimes add the -static option here so that we can build a | |||
# static executable that will run in a chroot jail. | |||
#LIB = -static | |||
@@ -60,9 +57,6 @@ | |||
# If using zlib: | |||
LIB += $(ZLIB_LIB.$(FOSSIL_ENABLE_MINIZ)) $(LDFLAGS) | |||
-# If using HTTPS: | |||
-LIB += -lcrypto -lssl | |||
- | |||
#### Tcl shell for use in running the fossil testsuite. If you do not | |||
# care about testing the end result, this can be blank. | |||
# |