mirror of
https://github.com/leonardw/synology-open-vm-tools.git
synced 2025-07-23 02:58:26 +00:00
synocli-file: add detox and rmlint
Update Docker image to Debian buster for scons Fix ncurses(w) detection with pkg-config
This commit is contained in:
22
Dockerfile
22
Dockerfile
@ -1,4 +1,4 @@
|
||||
FROM debian:stretch
|
||||
FROM debian:buster
|
||||
MAINTAINER SynoCommunity <https://synocommunity.com>
|
||||
|
||||
ENV LANG C.UTF-8
|
||||
@ -6,13 +6,10 @@ ENV LANG C.UTF-8
|
||||
# Manage i386 arch
|
||||
RUN dpkg --add-architecture i386
|
||||
|
||||
# Include backports for recent Meson build tool
|
||||
RUN echo "deb http://deb.debian.org/debian stretch-backports main contrib non-free" > /etc/apt/sources.list.d/stretch-backports.list
|
||||
|
||||
# Install required packages
|
||||
RUN apt-get update && \
|
||||
apt-get install --no-install-recommends -y automake \
|
||||
libtool \
|
||||
# Install required packages (in sync with README.rst instructions
|
||||
RUN apt-get update && apt-get install --no-install-recommends -y \
|
||||
autogen \
|
||||
automake \
|
||||
bc \
|
||||
bison \
|
||||
build-essential \
|
||||
@ -34,26 +31,29 @@ RUN apt-get update && \
|
||||
libcppunit-dev \
|
||||
libffi-dev \
|
||||
libgc-dev \
|
||||
libgmp3-dev \
|
||||
libltdl-dev \
|
||||
libmount-dev \
|
||||
libncurses-dev \
|
||||
libpcre3-dev \
|
||||
libssl-dev \
|
||||
libtool \
|
||||
libunistring-dev \
|
||||
unzip \
|
||||
lzip \
|
||||
mercurial \
|
||||
ncurses-dev \
|
||||
php \
|
||||
pkg-config \
|
||||
python3 \
|
||||
python3-distutils \
|
||||
scons \
|
||||
subversion \
|
||||
swig \
|
||||
unzip \
|
||||
xmlto \
|
||||
zlib1g-dev && \
|
||||
apt-get -t stretch-backports -y install meson && \
|
||||
apt-get clean && \
|
||||
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
# recent meson for fuse and sshfs
|
||||
|
||||
# Install setuptools, wheel and pip for Python3
|
||||
RUN wget https://bootstrap.pypa.io/get-pip.py -O - | python3
|
||||
|
@ -23,10 +23,10 @@ Virtual machine
|
||||
^^^^^^^^^^^^^^^
|
||||
A virtual machine based on an 64-bit version of Debian 10 stable OS is recommended. Non-x86 architectures are not supported.
|
||||
|
||||
* Install the requirements::
|
||||
* Install the requirements (in sync with Dockerfile)::
|
||||
|
||||
sudo dpkg --add-architecture i386 && sudo apt-get update
|
||||
sudo apt install build-essential debootstrap python-pip automake autogen libgmp3-dev libltdl-dev libunistring-dev libffi-dev libcppunit-dev libncurses-dev imagemagick libssl-dev pkg-config zlib1g-dev gettext git curl subversion check intltool gperf flex bison xmlto php expect libgc-dev mercurial cython lzip cmake swig libc6-i386 libmount-dev libpcre3-dev libbz2-dev
|
||||
sudo autogen automake bc bison build-essential check cmake curl cython debootstrap expect flex g++-multilib gettext git gperf imagemagick intltool libbz2-dev libc6-i386 libcppunit-dev libffi-dev libgc-dev libgmp3-dev libltdl-dev libmount-dev libncurses-dev libpcre3-dev libssl-dev libtool libunistring-dev lzip mercurial ncurses-dev php pkg-config python3 python3-distutils scons subversion swig unzip xmlto zlib1g-dev
|
||||
sudo pip install -U setuptools pip wheel httpie
|
||||
|
||||
* You may need to install some packages from testing like autoconf. Read about Apt-Pinning to know how to do that.
|
||||
|
18
cross/detox/Makefile
Normal file
18
cross/detox/Makefile
Normal file
@ -0,0 +1,18 @@
|
||||
PKG_NAME = detox
|
||||
PKG_VERS = 1.2.0
|
||||
PKG_EXT = tar.bz2
|
||||
PKG_DIR = $(PKG_NAME)-$(PKG_VERS)
|
||||
PKG_DIST_NAME = $(PKG_DIR).$(PKG_EXT)
|
||||
PKG_DIST_SITE = http://downloads.sourceforge.net/project/$(PKG_NAME)/$(PKG_NAME)/$(PKG_VERS)
|
||||
|
||||
DEPENDS =
|
||||
|
||||
HOMEPAGE = http://detox.sourceforge.net/
|
||||
COMMENT = Detox is a utility designed to clean up filenames
|
||||
LICENSE = BSD
|
||||
|
||||
GNU_CONFIGURE = 1
|
||||
|
||||
ENV += ac_cv_func_malloc_0_nonnull=yes ac_cv_func_realloc_0_nonnull=yes
|
||||
|
||||
include ../../mk/spksrc.cross-cc.mk
|
1
cross/detox/PLIST
Normal file
1
cross/detox/PLIST
Normal file
@ -0,0 +1 @@
|
||||
bin:bin/detox
|
3
cross/detox/digests
Normal file
3
cross/detox/digests
Normal file
@ -0,0 +1,3 @@
|
||||
detox-1.2.0.tar.bz2 SHA1 cfb88a1adefaf4ee3933baf9a6530c102baa47ce
|
||||
detox-1.2.0.tar.bz2 SHA256 abfad90ee7d3e0fc53ce3b9da3253f9a800cdd92e3f8cc12a19394a7b1dcdbf8
|
||||
detox-1.2.0.tar.bz2 MD5 da34c6bc3c68ce2fb008e25066e72927
|
11
cross/detox/patches/001-flex-noyywrap.patch
Normal file
11
cross/detox/patches/001-flex-noyywrap.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- config_file.l.orig 2019-09-22 18:08:53.288730250 +0200
|
||||
+++ config_file.l 2019-09-22 18:08:46.336515439 +0200
|
||||
@@ -44,6 +44,8 @@
|
||||
|
||||
%}
|
||||
|
||||
+%option noyywrap
|
||||
+
|
||||
%%
|
||||
|
||||
[\t ]+ { /* ignore whitespace */ }
|
@ -1,5 +1,5 @@
|
||||
PKG_NAME = file
|
||||
PKG_VERS = 5.30
|
||||
PKG_VERS = 5.35
|
||||
PKG_EXT = tar.gz
|
||||
PKG_DIST_NAME = $(PKG_NAME)-$(PKG_VERS).$(PKG_EXT)
|
||||
PKG_DIST_SITE = ftp://ftp.astron.com/pub/file/
|
||||
|
@ -1,3 +1,3 @@
|
||||
file-5.30.tar.gz SHA1 276051cd2c438d4e7a321c4422a5b3bc850fd747
|
||||
file-5.30.tar.gz SHA256 694c2432e5240187524c9e7cf1ec6acc77b47a0e19554d34c14773e43dbbf214
|
||||
file-5.30.tar.gz MD5 f35eaf05489ae566eafc4d26bb1dcd90
|
||||
file-5.35.tar.gz SHA1 a6f73580a93b768bfedd01ba54868375b7eb7bd0
|
||||
file-5.35.tar.gz SHA256 30c45e817440779be7aac523a905b123cba2a6ed0bf4f5439e1e99ba940b5546
|
||||
file-5.35.tar.gz MD5 5f10fb45bdaffd729a572e563783b78e
|
||||
|
@ -13,7 +13,7 @@ LICENSE = http://www.gnu.org/licenses/gpl.html
|
||||
|
||||
GNU_CONFIGURE = 1
|
||||
CONFIGURE_ARGS = --with-shared --enable-rpath --without-manpages --without-tests --enable-overwrite --disable-widec
|
||||
CONFIGURE_ARGS += --disable-home-terminfo
|
||||
CONFIGURE_ARGS += --disable-home-terminfo --enable-pc-files --with-pkg-config-libdir=$(INSTALL_PREFIX)/lib/pkgconfig
|
||||
CONFIGURE_ARGS += --disable-stripping --with-terminfo-dirs=$(INSTALL_PREFIX)/share/terminfo
|
||||
|
||||
include ../../mk/spksrc.cross-cc.mk
|
||||
|
@ -1,4 +1,4 @@
|
||||
# use a different package name (directory) for cross/ncursesw
|
||||
# use a different package name (directory) for cross/ncursesw
|
||||
# than for cross/ncurses to build into independent folders.
|
||||
PKG_NAME = ncursesw
|
||||
DIST_NAME = ncurses
|
||||
@ -21,19 +21,19 @@ POST_EXTRACT_TARGET = ncursesw_post_extract_target
|
||||
|
||||
GNU_CONFIGURE = 1
|
||||
CONFIGURE_ARGS = --with-shared --enable-rpath --without-manpages --without-tests --enable-overwrite --enable-widec
|
||||
CONFIGURE_ARGS += --disable-home-terminfo
|
||||
CONFIGURE_ARGS += --disable-home-terminfo --without-normal --enable-pc-files --with-pkg-config-libdir=$(INSTALL_PREFIX)/lib/pkgconfig
|
||||
CONFIGURE_ARGS += --disable-stripping --with-terminfo-dirs=$(INSTALL_PREFIX)/share/terminfo
|
||||
|
||||
include ../../mk/spksrc.cross-cc.mk
|
||||
|
||||
.PHONY: ncursesw_post_extract_target
|
||||
# Dist name and extracted package are the same for ncursesw and ncurses
|
||||
# We need a different folder for ncursesw here, since there exists spk that
|
||||
# include packages depending on ncurses and packages depending on ncursesw
|
||||
# (like synocli-file)
|
||||
# We get a different PKG_DIR for ncursesw by extracting to a temp folder
|
||||
# and then rename the target folder to ncursesw-$(PKG_VERS)
|
||||
# The temp folder is needed to be independent whether ncurses or ncursesw
|
||||
# is built first.
|
||||
ncursesw_post_extract_target:
|
||||
# Dist name and extracted package are the same for ncursesw and ncurses
|
||||
# We need a different folder for ncursesw here, since there exists spk that
|
||||
# include packages depending on ncurses and packages depending on ncursesw
|
||||
# (like synocli-file)
|
||||
# We get a different PKG_DIR for ncursesw by extracting to a temp folder
|
||||
# and then rename the target folder to ncursesw-$(PCK_VERS)
|
||||
# The temp folder is needed to be independent whether ncurses or ncursesw
|
||||
# is built first.
|
||||
@cd $(WORK_DIR) && mv temp/$(DIST_TARGET_DIR) $(PKG_DIR) && rm -rf temp
|
||||
|
26
cross/rmlint/Makefile
Normal file
26
cross/rmlint/Makefile
Normal file
@ -0,0 +1,26 @@
|
||||
PKG_NAME = rmlint
|
||||
PKG_VERS = 2.9.0
|
||||
PKG_EXT = tar.gz
|
||||
PKG_DIST_NAME = v$(PKG_VERS).$(PKG_EXT)
|
||||
PKG_DIST_SITE = https://github.com/sahib/rmlint/archive
|
||||
PKG_DIST_FILE=$(PKG_NAME)-v$(PKG_VERS).$(PKG_EXT)
|
||||
PKG_DIR = $(PKG_NAME)-$(PKG_VERS)
|
||||
|
||||
DEPENDS = cross/glib
|
||||
|
||||
HOMEPAGE = http://rmlint.rtfd.org/
|
||||
COMMENT = Extremely fast tool to remove duplicates and other lint from your filesystem.
|
||||
LICENSE = GPLv3
|
||||
|
||||
CONFIGURE_TARGET = none
|
||||
COMPILE_TARGET = rmlint_compile_target
|
||||
INSTALL_TARGET = rmlint_install_target
|
||||
|
||||
include ../../mk/spksrc.cross-cc.mk
|
||||
|
||||
.PHONY: rmlint_compile_target rmlint_install_target
|
||||
rmlint_compile_target:
|
||||
$(RUN) scons prefix=${STAGING_INSTALL_PREFIX} actual_prefix=$(INSTALL_PREFIX) VERBOSE=0 DEBUG=0 O=release
|
||||
|
||||
rmlint_install_target:
|
||||
$(RUN) install --mode=644 --target-directory=${STAGING_INSTALL_PREFIX}/bin/ ./rmlint
|
1
cross/rmlint/PLIST
Normal file
1
cross/rmlint/PLIST
Normal file
@ -0,0 +1 @@
|
||||
bin:bin/rmlint
|
3
cross/rmlint/digests
Normal file
3
cross/rmlint/digests
Normal file
@ -0,0 +1,3 @@
|
||||
rmlint-v2.9.0.tar.gz SHA1 f0715b87a7d9a50fd3150c1ee95abc350c460e2c
|
||||
rmlint-v2.9.0.tar.gz SHA256 a2d26863e0018efad60f0b1123e7cffd8ef764c8fb574a7987a49260e4e51c8f
|
||||
rmlint-v2.9.0.tar.gz MD5 b2a0ba67c3f6914e584354a173537ca9
|
11
cross/rmlint/patches/001-scons-pkg-config-libdir.patch
Normal file
11
cross/rmlint/patches/001-scons-pkg-config-libdir.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- SConstruct.orig 2019-09-22 14:00:34.610189122 +0200
|
||||
+++ SConstruct 2019-09-22 13:59:57.096414135 +0200
|
||||
@@ -558,7 +558,7 @@
|
||||
PREFIX=GetOption('prefix'),
|
||||
ENV = dict([ (key, os.environ[key])
|
||||
for key in os.environ
|
||||
- if key in ['PATH', 'TERM', 'HOME', 'PKG_CONFIG_PATH']
|
||||
+ if key in ['PATH', 'TERM', 'HOME', 'PKG_CONFIG_PATH', 'PKG_CONFIG_LIBDIR']
|
||||
])
|
||||
)
|
||||
|
19
diyspk/detox/Makefile
Normal file
19
diyspk/detox/Makefile
Normal file
@ -0,0 +1,19 @@
|
||||
SPK_NAME = detox
|
||||
PKG_VERS = 1.2.0
|
||||
SPK_REV = 1
|
||||
SPK_ICON = src/detox_logo.jpg
|
||||
|
||||
DEPENDS = cross/detox
|
||||
|
||||
MAINTAINER = SynoCommunity
|
||||
DESCRIPTION = Detox is a utility designed to clean up filenames
|
||||
DISPLAY_NAME = detox
|
||||
STARTABLE = no
|
||||
BETA = 1
|
||||
|
||||
HOMEPAGE = http://detox.sourceforge.net/
|
||||
LICENSE = BSD
|
||||
|
||||
SERVICE_SETUP = src/service-setup.sh
|
||||
|
||||
include ../../mk/spksrc.spk.mk
|
BIN
diyspk/detox/src/detox_logo.jpg
Normal file
BIN
diyspk/detox/src/detox_logo.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.9 KiB |
13
diyspk/detox/src/service-setup.sh
Normal file
13
diyspk/detox/src/service-setup.sh
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
service_postinst ()
|
||||
{
|
||||
# Put less in the PATH
|
||||
mkdir -p /usr/local/bin
|
||||
ln -s /var/packages/${SYNOPKG_PKGNAME}/target/bin/detox /usr/local/bin/detox
|
||||
}
|
||||
|
||||
service_postuninst ()
|
||||
{
|
||||
# Remove link
|
||||
rm -f /usr/local/bin/detox
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
SPK_NAME = file
|
||||
SPK_VERS = 5.30
|
||||
SPK_VERS = 5.35
|
||||
SPK_REV = 1
|
||||
|
||||
DEPENDS = cross/file
|
||||
|
@ -1,6 +1,6 @@
|
||||
SPK_NAME = nano
|
||||
SPK_VERS = 2.9.8
|
||||
SPK_REV = 5
|
||||
SPK_VERS = 4.4
|
||||
SPK_REV = 6
|
||||
SPK_ICON = src/nano.png
|
||||
|
||||
DEPENDS = cross/$(SPK_NAME)
|
||||
@ -11,7 +11,6 @@ DESCRIPTION_GER = nano ist ein einfacher Editor, der die Bearbeitung von Dateien
|
||||
RELOAD_UI = no
|
||||
DISPLAY_NAME = nano
|
||||
STARTABLE = no
|
||||
CHANGELOG = "Update to 2.9.8."
|
||||
|
||||
HOMEPAGE = http://www.nano-editor.org
|
||||
LICENSE = GPLv2
|
||||
|
20
diyspk/rmlint/Makefile
Normal file
20
diyspk/rmlint/Makefile
Normal file
@ -0,0 +1,20 @@
|
||||
SPK_NAME = rmlint
|
||||
SPK_VERS = 2.9.0
|
||||
SPK_REV = 1
|
||||
SPK_ICON = src/rmlint-logo.png
|
||||
|
||||
DEPENDS = cross/rmlint
|
||||
|
||||
MAINTAINER = SynoCommunity
|
||||
DESCRIPTION = rmlint finds space waste and other broken things on your filesystem and offers to remove it.
|
||||
DISPLAY_NAME = rmlint
|
||||
STARTABLE = no
|
||||
BETA = 1
|
||||
|
||||
HOMEPAGE = https://github.com/sahib/rmlint
|
||||
LICENSE = GPLv3
|
||||
HELP_URL = https://rmlint.readthedocs.io/en/latest/
|
||||
|
||||
SERVICE_SETUP = src/service-setup.sh
|
||||
|
||||
include ../../mk/spksrc.spk.mk
|
BIN
diyspk/rmlint/src/rmlint-logo.png
Normal file
BIN
diyspk/rmlint/src/rmlint-logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 12 KiB |
13
diyspk/rmlint/src/service-setup.sh
Normal file
13
diyspk/rmlint/src/service-setup.sh
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
service_postinst ()
|
||||
{
|
||||
# Put less in the PATH
|
||||
mkdir -p /usr/local/bin
|
||||
ln -s /var/packages/${SYNOPKG_PKGNAME}/target/bin/rmlint /usr/local/bin/rmlint
|
||||
}
|
||||
|
||||
service_postuninst ()
|
||||
{
|
||||
# Remove link
|
||||
rm -f /usr/local/bin/rmlint
|
||||
}
|
@ -14,9 +14,9 @@ endif
|
||||
MAINTAINER = SynoCommunity
|
||||
DISPLAY_NAME = SynoCli File Tools
|
||||
ifneq ($(findstring $(ARCH), powerpc ppc824x ppc853x ppc854x $(ARM5_ARCHES)),$(ARCH))
|
||||
DESCRIPTION = "SynoCli File Tools provides a set of small command-line utilities: less, tree, ncdu, jdupes, rhash, mc \(midnight commander\), nano, file, rnm."
|
||||
DESCRIPTION = "SynoCli File Tools provides a set of small command-line utilities: less, tree, ncdu, jdupes, rhash, mc \(midnight commander\), nano, file, detox, rmlint, rnm."
|
||||
else
|
||||
DESCRIPTION = "SynoCli File Tools provides a set of small command-line utilities: less, tree, ncdu, jdupes, rhash, mc \(midnight commander\), nano, file."
|
||||
DESCRIPTION = "SynoCli File Tools provides a set of small command-line utilities: less, tree, ncdu, jdupes, rhash, mc \(midnight commander\), nano, file, detox, rmlint."
|
||||
endif
|
||||
|
||||
STARTABLE = no
|
||||
|
@ -1,4 +1,4 @@
|
||||
COMMANDS="jdupes less lessecho lesskey tree rhash rnm nano rnano ncdu file"
|
||||
COMMANDS="jdupes less lessecho lesskey tree rhash rnm nano rnano ncdu file detox rmlint"
|
||||
RHASH_COMMAND_LINKS="ed2k-link edonr256-hash edonr512-hash gost-hash has160-hash magnet-link sfv-hash tiger-hash tth-hash whirlpool-hash"
|
||||
MC_COMMAND_LINKS="mc mcedit mcdiff mcview"
|
||||
|
||||
|
Reference in New Issue
Block a user