mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
seafile: import version 5.1.1 and its dependencies
Signed-off-by: Gergely Kiss <mail.gery@gmail.com>
This commit is contained in:
committed by
Etienne CHAMPETIER
parent
39e937fae7
commit
437621931a
+40
-62
@@ -1,29 +1,28 @@
|
||||
#
|
||||
# Copyright (C) 2007-2015 OpenWrt.org
|
||||
# Copyright (C) 2007-2016 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
# NOTE: make sure to update EXTRA_DEPENDS in case of version/release changes!
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=seafile-server
|
||||
PKG_VERSION:=4.1.2
|
||||
PKG_RELEASE=$(PKG_SOURCE_VERSION)-5
|
||||
PKG_VERSION:=5.1.1
|
||||
PKG_RELEASE=$(PKG_SOURCE_VERSION)-1
|
||||
PKG_LICENSE:=GPL-3.0
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=https://github.com/haiwen/seafile.git
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_SOURCE_VERSION:=c0166019c712e2e1d5e532fd5f7401b1b72db6d8
|
||||
PKG_SOURCE_VERSION:=5a8677a3acdde748caa387adfc054da64f2a24ea
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
|
||||
PKG_FIXUP:=autoreconf
|
||||
PKG_INSTALL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include $(INCLUDE_DIR)/nls.mk
|
||||
$(call include_mk, python-package.mk)
|
||||
|
||||
define Package/seafile-server
|
||||
SECTION:=net
|
||||
@@ -31,21 +30,16 @@ define Package/seafile-server
|
||||
TITLE:=Seafile server
|
||||
MAINTAINER:=Gergely Kiss <mail.gery@gmail.com>
|
||||
URL:=http://seafile.com/
|
||||
DEPENDS:=+libarchive +libopenssl +glib2 +libsearpc +seafile-ccnet +seafile-seahub \
|
||||
+sqlite3-cli +python-mysql +jansson +libevent2 +libevent2-openssl +zlib +libzdb +libsqlite3 \
|
||||
+libmysqlclient +libpthread +libuuid \
|
||||
+bash +sudo +procps-ng +procps-ng-pkill $(ICONV_DEPENDS)
|
||||
EXTRA_DEPENDS:=seafile-ccnet (=4.1.2-a73109f09af4ecc49cdc4c57cdde51b38e15c31a-2), seafile-seahub (=4.1.2-3fb1288f920de03a4e2e6a06b60671ce98971742)
|
||||
DEPENDS:=+libarchive +libopenssl +glib2 +libsearpc +seafile-ccnet +seafile-seahub +sqlite3-cli +python-mysql \
|
||||
+jansson +libevent2 +libevent2-openssl +zlib +libzdb +libsqlite3 +libmysqlclient +libevhtp \
|
||||
+libpthread +libuuid +bash +procps +procps-pkill $(ICONV_DEPENDS)
|
||||
EXTRA_DEPENDS:=seafile-ccnet (=5.1.1-6d94fdc4296d542a5552039dc13a67c3448e8b13-1), seafile-seahub (=5.1.1-95f762f396c81f840fe658ab983df53784083bb1-1), libevhtp (>=1.2.10)
|
||||
endef
|
||||
|
||||
define Package/seafile-server/description
|
||||
Open source cloud storage with advanced features on privacy protection and teamwork.
|
||||
endef
|
||||
|
||||
define Package/seafile-server/conffiles
|
||||
/etc/config/seafile
|
||||
endef
|
||||
|
||||
CONFIGURE_ARGS += --disable-riak \
|
||||
--disable-client \
|
||||
--disable-fuse \
|
||||
@@ -55,87 +49,71 @@ CONFIGURE_ARGS += --disable-riak \
|
||||
--disable-server-pkg \
|
||||
--disable-console
|
||||
|
||||
PKG_BUILD_DEPENDS:=vala/host \
|
||||
libsearpc/host \
|
||||
libevhtp-1.1
|
||||
PKG_BUILD_DEPENDS:=vala/host
|
||||
|
||||
TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib -liconv \
|
||||
-L$(STAGING_DIR)/usr/lib/mysql -lmysqlclient -lz
|
||||
|
||||
define Package/seafile-server/conffiles
|
||||
/etc/config/seafile
|
||||
endef
|
||||
|
||||
define Package/seafile-server/install
|
||||
$(INSTALL_DIR) $(1)/usr/{bin,lib}
|
||||
$(INSTALL_DIR) $(1)/usr/lib/python2.7/site-packages
|
||||
$(INSTALL_DIR) $(1)/usr/share/seafile/seafile-server/runtime
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_DIR) $(1)/etc/config
|
||||
$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
|
||||
$(INSTALL_DIR) $(1)/usr/share/seafile/seafile-server
|
||||
$(INSTALL_DIR) $(1)/usr/share/seafile/conf
|
||||
$(INSTALL_DIR) $(1)/etc/{config,init.d}
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/python2.7/site-packages/seafile/ $(1)/usr/lib/python2.7/site-packages/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/python2.7/site-packages/seaserv/ $(1)/usr/lib/python2.7/site-packages/
|
||||
$(CP) $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/seafile/ $(1)$(PYTHON_PKG_DIR)/
|
||||
$(CP) $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/seaserv/ $(1)$(PYTHON_PKG_DIR)/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libseafile.so* $(1)/usr/lib/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/seaf-gc.sh $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/seaf-fsck.sh $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/setup-seafile-mysql.py $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/setup-seafile-mysql.sh $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/sqlite2mysql.py $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/sqlite2mysql.sh $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/check_init_admin.py $(1)/usr/share/seafile/seafile-server/
|
||||
$(CP) $(PKG_BUILD_DIR)/scripts/upgrade/ $(1)/usr/share/seafile/seafile-server/
|
||||
$(INSTALL_BIN) ./files/seafile.init $(1)/etc/init.d/seafile
|
||||
$(CP) ./files/seafile.conf $(1)/etc/config/seafile
|
||||
$(INSTALL_BIN) ./files/seafile.init $(1)/etc/init.d/seafile
|
||||
$(INSTALL_BIN) ./files/seahub.init $(1)/etc/init.d/seahub
|
||||
find $(1) -name "*\.pyc" -o -name "*\.pyo" | xargs rm -f
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include
|
||||
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
||||
$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/seafile/ $(1)/usr/include/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libseafile.pc $(1)/usr/lib/pkgconfig/
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libseafile.so* $(1)/usr/lib/
|
||||
$(CP) $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/seafile/ $(1)$(PYTHON_PKG_DIR)/
|
||||
$(CP) $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/seaserv/ $(1)$(PYTHON_PKG_DIR)/
|
||||
endef
|
||||
|
||||
define Package/seafile-server/postinst
|
||||
#!/bin/sh
|
||||
|
||||
if ! group_exists seafile; then
|
||||
group_add_next seafile; fi
|
||||
|
||||
SEAFILE_GID=$$(grep -s '^seafile:' "$${IPKG_INSTROOT}/etc/group" | cut -d: -f3)
|
||||
|
||||
if ! user_exists seafile; then
|
||||
user_add seafile "" "$${SEAFILE_GID}" seafile /usr/share/seafile /bin/sh; fi
|
||||
|
||||
if [ -z "$${IPKG_INSTROOT}" ]
|
||||
if [ ! -d /usr/share/seafile/seafile-data ]
|
||||
then
|
||||
chown -R seafile:seafile /usr/share/seafile/
|
||||
chmod -R o-rwx /usr/share/seafile/
|
||||
echo "*** Installation completed, running configuration script..."
|
||||
/etc/init.d/seafile setup
|
||||
|
||||
if [ ! -d /usr/share/seafile/seafile-data ]
|
||||
if [ $$? -ne 0 ]
|
||||
then
|
||||
echo "*** Installation completed, running configuration script..."
|
||||
/etc/init.d/seafile setup
|
||||
|
||||
if [ $$? -ne 0 ]
|
||||
then
|
||||
echo
|
||||
echo "*** ERROR: Configuration failed. Please fix the issues if any and re-run the script using the command below:"
|
||||
echo "*** \"/etc/init.d/seafile setup\""
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "*** NOTE: you need to create an admin account before using Seafile."
|
||||
echo "*** Please run \"/etc/init.d/seafile create_admin\" to do so."
|
||||
else
|
||||
echo "*** It seems you are upgrading from an older version."
|
||||
echo "*** If so, please run the appropriate upgrade scripts before using the new version of Seafile."
|
||||
echo "*** Upgrade scripts are located at \"/usr/share/seafile/seafile-server/upgrade\""
|
||||
echo
|
||||
echo "*** For more information, please read http://manual.seafile.com/deploy/upgrade.html"
|
||||
echo "*** ERROR: Configuration failed. Please fix the issues if any and re-run the script using the command below:"
|
||||
echo "*** \"/etc/init.d/seafile setup\""
|
||||
fi
|
||||
else
|
||||
cat > "$${IPKG_INSTROOT}/etc/uci-defaults/99_seafile-server" << EOF
|
||||
#!/bin/sh
|
||||
|
||||
chown -R seafile:seafile /usr/share/seafile/
|
||||
chmod -R o-rwx /usr/share/seafile/
|
||||
exit 0
|
||||
EOF
|
||||
echo "*** seafile-data directory already exists."
|
||||
echo "*** In case you are upgrading seafile, please run the appropriate upgrade script"
|
||||
echo "*** manually before using the new version of Seafile."
|
||||
echo "*** Upgrade scripts are located at \"/usr/share/seafile/seafile-server/upgrade\""
|
||||
echo
|
||||
echo "*** For more information, please read http://manual.seafile.com/deploy/upgrade.html"
|
||||
fi
|
||||
endef
|
||||
|
||||
|
||||
Reference in New Issue
Block a user