Hi All,
The IPFire-3.x version of python3-setuptools is quite old so I thought I would have a go at updating it but had a few problems on the way.
Running the existing version for 65.6.3 results in
Building python3-setuptools-65.6.3-1.ipfire3.src... python3-setuptools-65.6.3-1.ipfire3.src does not support being built on x86_64 OSError: [Errno 0] Error
Removing the line from the build section that has arches = noarch stops that error occurring. Most of the other python3 .nm files don't have that arches line present.
Trying to then run version 68.2.2 resulted in the error Could not add 'setuptools-68.2.2.tar.gz' to package: Success
Testing out the download url I found that it works with version 65.6.3 but not with 68.2.2. Looking at the download from PyPI I found that other parts of the download url are changed for different versions of the same package.
The download url for 65.6.3 and for 68.2.2 are shown below for comparison
https://files.pythonhosted.org/packages/b6/21/cb9a8d0b2c8597c83fce8e9c02884b... https://files.pythonhosted.org/packages/ef/cc/93f7213b2ab5ed383f98ce8020e632...
The above means that each time the version number is changed the download url will also need to be manually edited for all downloads from PyPI.
After changing the download url then the package downloaded and was successfully built.
Regards,
Adolf.
Hello Adolf,
On 21 Sep 2023, at 19:25, Adolf Belka adolf.belka@ipfire.org wrote:
Hi All,
The IPFire-3.x version of python3-setuptools is quite old so I thought I would have a go at updating it but had a few problems on the way.
Running the existing version for 65.6.3 results in
Building python3-setuptools-65.6.3-1.ipfire3.src... python3-setuptools-65.6.3-1.ipfire3.src does not support being built on x86_64 OSError: [Errno 0] Error
Removing the line from the build section that has arches = noarch stops that error occurring. Most of the other python3 .nm files don't have that arches line present.
Yes, this is a “feature”. Some packages do not depend on a specific architecture. For example a package that only ships a shell script which would run on any architecture that has a shell. In that case, we won’t need to compile the same packages multiple times for each supported architecture, but we only create one package that has “noarch” as its architecture.
To tell the build system that, there is a variable called “arches” in the build section of the makefile. The variable could also have “x86_64” in it if something is not support on let’s say aarch64:
https://git.ipfire.org/?p=ipfire-3.x.git;a=blob;f=hyperscan/hyperscan.nm;h=7...
Because the build system is set up first, and then we look at the package we are supposed to build, we require that you pass the architecture you want to build for on the command line. The default is the architecture of your build system.
Trying to then run version 68.2.2 resulted in the error Could not add 'setuptools-68.2.2.tar.gz' to package: Success
This is a slightly bad error message from the downloader. I will put this on my list to make it clearer what it actually is complaining about.
Testing out the download url I found that it works with version 65.6.3 but not with 68.2.2. Looking at the download from PyPI I found that other parts of the download url are changed for different versions of the same package.
The download url for 65.6.3 and for 68.2.2 are shown below for comparison
https://files.pythonhosted.org/packages/b6/21/cb9a8d0b2c8597c83fce8e9c02884b... https://files.pythonhosted.org/packages/ef/cc/93f7213b2ab5ed383f98ce8020e632...
This is inconvenient, but it seems that this is the only way to do this then…
-Michael
The above means that each time the version number is changed the download url will also need to be manually edited for all downloads from PyPI.
After changing the download url then the package downloaded and was successfully built.
Regards,
Adolf.
--
Sent from my laptop