Closed TimvdEijnden closed 5 years ago
I've tried the following:
git clone https://github.com/SynoCommunity/spksrc.git ~/git/spksrc
docker pull synocommunity/spksrc
docker run -it -v ~/git/spksrc:/spksrc synocommunity/spksrc /bin/bash
Inside the docker container:
make setup
cd spk/deluge/
make arch-armada37xx-6.2
Output from make:
===> Building package for arch armada37xx-6.2
make[1]: Entering directory '/spksrc/spk/deluge'
===> Set up toolchain
===> Extracting for syno-armada37xx
tar -xpf /spksrc/toolchains/syno-armada37xx-6.2/../../distrib/toolchains/6.2/rtd1296-gcc494_glibc220_armv8-GPL.txz -C /spksrc/toolchains/syno-armada37xx-6.2/work
tar: aarch64-unknown-linux-gnueabi/build.log.bz2: Cannot open: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/lib32: Cannot create symlink to ‘lib’: No such file or directory
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/lib64: Cannot create symlink to ‘lib’: No such file or directory
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/sys-root: Cannot mkdir: No such file or directory
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/sys-root/usr: Cannot mkdir: No such file or directory
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/sys-root/usr/include: Cannot mkdir: No such file or directory
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/sys-root/usr/include/mtd: Cannot mkdir: No such file or directory
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi: Cannot mkdir: Permission denied
tar: aarch64-unknown-linux-gnueabi/aarch64-unknown-linux-gnueabi/sys-root/usr/include/mtd/nftl-user.h: Cannot open: No such file or director
So the extraction failed, i extracted it manually in macOs and changed the extract_target
function in spksrc.extract.mk to so it will not fail on existing folder/files
extract_target: $(PRE_EXTRACT_TARGET)
@mkdir -p $(EXTRACT_PATH) && true
$(EXTRACT_CMD) && true
And now it's still running
It is a known issue that macOS Docker is in trouble extracting .tar.gz...
Deluge has not been updated since aarch64
architecture introduction for ARM v8 platforms.
I am publishing current version for this arch.
The spk is created, but It won't run after installing it.
There were still some issues along the way, here's how I've fixed them:
GeoIP failed to download https://github.com/maxmind/geoip-api-c/releases/download/v1.6.9.tar.gz because it gives a 404. This link works but https://github.com/maxmind/geoip-api-c/archive/v1.6.9.tar.gz but the checksum and content does not match
. So I've found an alternative link and manually moved it to the correct location.
Then almost at the end I got this error:
Stripping lib/libtorrent-rasterbar.so.8.0.0... chmod: cannot access '/spksrc/spk/deluge/work-armada37xx-6.2/staging/lib/libtorrent-rasterbar.so.8.0.0': No such file or directory
../../mk/spksrc.strip.mk:49: recipe for target 'strip_target' failed
make[1]: *** [strip_target] Error 1
make[1]: Leaving directory '/spksrc/spk/deluge'
../../mk/spksrc.spk.mk:452: recipe for target 'arch-armada37xx-6.2' failed
make: [arch-armada37xx-6.2] Error 2 (ignored)
Fixed by doing:
ln -s /var/packages/deluge/target/lib/libtorrent-rasterbar.so.8.0.0 /spksrc/spk/deluge/work-armada37xx-6.2/staging/lib/libtorrent-rasterbar.so.8.0.0
and repeating make arch-armada37xx-6.2
again.
Here's a link for anyone interested: https://www.dropbox.com/s/t1ly7ynlwokceuy/deluge_armada37xx-6.2_1.3.15-9.spk?dl=0
The log file /volume1/@appstore/deluge/var/deluge.log shows:
[INFO ] 21:31:53 configmanager:70 Setting config directory to: /volume1/@appstore/deluge/var/
[INFO ] 21:35:16 daemon:127 Deluge daemon 1.3.15
[INFO ] 21:35:25 configmanager:70 Setting config directory to: /volume1/@appstore/deluge/var/
[ERROR ] 21:36:14 main:248 libtorrent-rasterbar.so.8: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "/volume1/@appstore/deluge/env/lib/python2.7/site-packages/deluge-1.3.15-py2.7.egg/deluge/main.py", line 241, in start_daemon
Daemon(options, args)
File "/volume1/@appstore/deluge/env/lib/python2.7/site-packages/deluge-1.3.15-py2.7.egg/deluge/core/daemon.py", line 144, in __init__
from deluge.core.core import Core
File "/volume1/@appstore/deluge/env/lib/python2.7/site-packages/deluge-1.3.15-py2.7.egg/deluge/core/core.py", line 38, in <module>
from deluge._libtorrent import lt
File "/volume1/@appstore/deluge/env/lib/python2.7/site-packages/deluge-1.3.15-py2.7.egg/deluge/_libtorrent.py", line 59, in <module>
import libtorrent as lt
ImportError: libtorrent-rasterbar.so.8: cannot open shared object file: No such file or directory
I wonder why libtorrent-rasterbar.so
is not included in generated wheel python_libtorrent-1.0.11-cp27-cp27mu-linux_x86_64.whl
like libtorrent.so
is...
Sounds like time to update everything.
Have you got any opinion about it @Safihre ?
I made changes about PLIST
generation so it explains why libtorrent-rasterbar.so
is no longer copies into deluge
staging.
@ymartin59 just let me know if I can do anything
@ymartin59 It's been too long ago for me to remember the details, and not a deluge user to test things..
@ymartin59 I got a working version now.
Earlier on I symlinked libtorrent-rasterbar.so.8.0.0
. Now I've copied the contents:
cp /var/packages/deluge/target/lib/libtorrent.* /spksrc/spk/deluge/work-armada37xx-6.2/staging/lib/
And now it's running. https://www.dropbox.com/s/i2uxm9hzorz501k/deluge_armada37xx-6.2_1.3.15-9.spk?dl=0
@TimvdEijnden Thanks for the tip.
I have found the proper fix in libtorrent
Makefile: https://github.com/SynoCommunity/spksrc/commit/536c78398ed1831afab9163713d110bc9bcd9eb1
Please confirm installing: https://packages.synocommunity.com/deluge/9/deluge.v9.f15047[rtd1296-armada37xx-aarch64].spk
Now available from Package Center too: https://synocommunity.com/package/deluge
@ymartin59 once I'm back home I'll try it. How do packages get published to synocommunity?
@ymartin59 Yes it works!
Setup
Package Name: Deluge Package Version: v1.3.15-9
NAS Model: DS119J NAS Architecture: 6.1 armada37xx (MARVELL Armada 3720 88F3720) DSM version: DSM 6.2.1-23824 Update 6
Expected behavior
The package is not available and cannot be installed
Actual behavior
The package should be able to install
If someone can help me get started to build such a package I'm willing to help out. @ymartin59 @KosakAlmighty @hgy59 @William0702 @Jumbotroll Maybe one of you knows?