SynoCommunity / spksrc

Cross compilation framework to create native packages for the Synology's NAS
https://synocommunity.com
Other
3.03k stars 1.23k forks source link

Compiling Python for rtd1296 help needed #3009

Closed WodKa78 closed 6 years ago

WodKa78 commented 6 years ago

Trying to compile Python for arch-rtd1296 following but end up with an error i can't solve. I first compiled native and cross and final tried to compile the spk. Error:

checking build system type... i686-pc-linux-gnu checking host system type... aarch64-unknown-linux-gnueabi checking target system type... aarch64-unknown-linux-gnueabi continue configure in default builddir "./aarch64-unknown-linux-gnueabi" ....exec /bin/bash .././configure "--srcdir=.." "--enable-builddir=aarch64-unknown-linux-gnueabi" "linux gnueabi" .././configure: line 2356: config.log: Invalid argument .././configure: line 2366: config.log: Invalid argument ../../mk/spksrc.configure.mk:50: recipe for target 'configure_target' failed make[3]: [configure_target] Error 1 make[3]: Leaving directory '/spksrc/cross/libffi' ../../mk/spksrc.depend.mk:44: recipe for target 'depend_target' failed make[2]: [depend_target] Error 2 make[2]: Leaving directory '/spksrc/cross/cffi' ../../mk/spksrc.depend.mk:44: recipe for target 'depend_target' failed make[1]: *** [depend_target] Error 2 make[1]: Leaving directory '/spksrc/spk/python' ../../mk/spksrc.spk.mk:419: recipe for target 'arch-rtd1296-6.1' failed make: [arch-rtd1296-6.1] Error 2 (ignored)>

Was able to succesfully other packages but with this one i'm stuck and lost (not a programmer, just try to make my NAS do what i want)

Anybody who can help me solve this? Help is much appriciated

Safihre commented 6 years ago

Which toolchain are you using? For DSM6? As I wrote here, I also tried compiling Python for DSM6 and getting a whole range of problems. The cross/python compiles fine, it's just that the spk fails on all platforms using the new toolchains. The spk is such a giant package in terms of other depdendecies, I don't even know where to start. As you can see here I tried to compile it in a bunch of different ways. Biggest problem now seems to be cffi, just like you are having. Something is going wrong with the new toolchains....

Safihre commented 6 years ago

I was actually thinking of starting small, just compile the spk/python with only cross/python and then slowly start adding dependencies. So remove all DEPENDS/BUILD_DEPENDS/WHEELS and try to build. However, I don't have a Synology myself so I can't even test the packages.

WodKa78 commented 6 years ago

yes DSM6 ( syno-rtd1296-6.1 tool chain to be more precise) Hope the community has some suggestions to solve it as this goes way above my paygrade.

But will not give up since i am also learning from it ;-)

ymartin59 commented 6 years ago

To run make arch-rtd1296-6.1, it is required to checkout branch dsm6

Safihre commented 6 years ago

@ymartin59: of course I did, but it does not work. The main problem is that cffi won't compile. Additionally, the dependencies zmq, libsodium and curl cross packages don't compile due to the source files not being available. I made a couple of attempts to fix: https://github.com/Safihre/spksrc/commits/dsm61-travis

What I do not understand is why the spk/python has so many dependencies? Shouldn't they all be specific to the packages that need them? And why are some dependencies in cross while others are via requirements?

Safihre commented 6 years ago

I managed to fix the cffi problem by updating the native/python package to not install the old cffi==1.9 and use the latest setuptools. However, now libsodium (dependency of zmq / pyzmq) is giving problems. https://travis-ci.org/Safihre/spksrc/builds/305174629

WodKa78 commented 6 years ago

@Safihre I can help testing and reporting but afraid I have too little (almost none) knowledge to be of anymore help. Of course with some guides and guiding I might be able to do little more ones pushed in the right directions.

Safihre commented 6 years ago

@WodKa78 What app are you going to run with python? SABnnzbd/Sickrage/CP?

WodKa78 commented 6 years ago

Maraschino and nzbhydra.

AidenJ2409 commented 6 years ago

@Safihre if you need more testers, i want to run SickRage/CP.

Safihre commented 6 years ago

@ymartin59 I managed to get the package compiled after disabling a number of cross dependencies for spk/python, moving some of them to the requirements file and disabled some others that I wasn't sure why they were needed. The ones that failed to compile for various reasons (missing headers or other dependencies) are m2crypto, uwsgi, pycurl and pillow.

@WodKa78 @AidenJ2409 The Python package will appear soon here: https://github.com/Safihre/spksrc/releases/tag/python-5-dms61 Let me know if it works!

AidenJ2409 commented 6 years ago

@Safihre Works here on my end. The package installed without any problem.

I tried the modified CP and SR package that you provides after that and they also installed without any problem.

I own a Ds218Play with the rtd1296 CPU btw.

Update: I uninstalled and reinstalled the Python package and now whenever i try to install the CP and SR package, i get a error that says "unavailable" as soon as i want to install them.

Update2: I dont know if its just my network that had a hickup but as soon as i installed the python package my network share for the nas dissapeared from my windowsexplorer window. When i removed the python package it came back. Is this a coincidence or? (:

Update3: Sorry for all the text, but i'm trying to be helpfull here haha. After a reboot from the Nas both CP and SR installed without any message or problem. I hope i can set both programs up today so i can give some more info..

Safihre commented 6 years ago

Yes, we of course want to know if your apps work as expected :)

WodKa78 commented 6 years ago

@Safihre seems working fine witht the spk's i've compiled before, i will do good testing during the weekend and let you know how it goes. thanks a lot for the great effort :)

banshee1971 commented 6 years ago

I re-try everytinh.

Install the Mono from Synology, and Stop. Then Mono from WodKa78 Sabnzb Sonnar and Radar MediaInfo Edit the 2 file using Putty (wasn't able to start Sonar without this) Add Read/Write Access to the downloads folder and my VideoFile to the 2 SynoGroup, and sonar and Radar user.

Reboot NAS

SabNZB works fine ! (i test it without issue)

Sonar seem able to search series, but told me "Folder is not writable by user sc-sonarr" But the "system internal user" sc-sonarr, sc-radarr and sc-sabnzb" have read/write access there !

I remove the right, re-add... reboot nas. Same result.

Any clue ?

note : Thanks for those package ! very appreciated :) 👍

banshee1971 commented 6 years ago

Weird... is as write access to downloads folder... but not the other i just create...

WodKa78 commented 6 years ago

@banshee1971 seems your problem is not related to this issue so i suggest to open a new issue for your problem. Contributing

I the mean time make sure user sc-sonar has read/write acces to all subfolders as well not only the main dir.

banshee1971 commented 6 years ago

100% True... found it... right issue.

Fixed now !

Thanks for you're help 👍

WodKa78 commented 6 years ago

@Safihre running smoothly still.

TonVH commented 6 years ago

I have DL'ed Python and installed Sickrage. As far as I can tell it works fine. Thx for all the work.

ymartin59 commented 6 years ago

@Safihre What is current status with troubles concerning "temporarily" published Python 2.7.14-17 ? Is there still pending issues to fix ?

Safihre commented 6 years ago

@ymartin59 unfortunately, yes. Have not have time to fix this weird issue with Deluge that throws this error about Cryptography/Openssl. Will push changes here as soon as possible when I figured it out!

ymartin59 commented 6 years ago

OK, I propose to test and fix Python and Deluge packages all together in a single PR with Deluge update and port to generic service. Not in my plans yet. Will see whoever grabs it first.

ymartin59 commented 6 years ago

@Safihre python 2.7 update is pending (since a while) because of Deluge trouble. May you please work on Deluge package update+service support so that we may test python+deluge packages and investigate ? Again many thanks for your help and support in SynoCommunity

Safihre commented 6 years ago

@ymartin59 I can do that Deluge conversion, but even after that I am afraid the problems only occur with non-x86 systems. And those can't be simulated with XPEnology right? I would actually have to get some second-hand ARM Synology to test I think.

Safihre commented 6 years ago

Python packages should soon be available (#3156) but for now test-packages of #3138 seem to work 👍