[aur-general] Issue python PKGBUILD
Hi, After a new release of a python module, I'm facing an issue to update the PKGBUILD. I get a permission error in the package() section: Traceback (most recent call last): File "setup.py", line 52, in <module> setup( File "/usr/lib/python3.8/site-packages/skbuild/setuptools_wrap.py", line 639, in setup _copy_file(data_file, dest_data_file, hide_listing) File "/usr/lib/python3.8/site-packages/skbuild/setuptools_wrap.py", line 828, in _copy_file copyfile(src_file, dest_file) File "/usr/lib/python3.8/shutil.py", line 259, in copyfile with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst: PermissionError: [Errno 13] Permission denied: '_skbuild/linux-x86_64-3.8/ cmake-install/src/third-party/headers/muparserx/.git/objects/pack/pack- bcece967ee9ec3297e6c8709d2c6d670ad7e3af2.idx' However, if I execute python setup.py install --root="test-install" -- optimize=1 --skip-build manually I cannot replicate the error. Is there any difference between when makepkg executes that command and when I do it myself? Thanks, Iyán
On 2/6/20 6:10 PM, Iyán Méndez Veiga wrote:
Hi,
After a new release of a python module, I'm facing an issue to update the PKGBUILD. I get a permission error in the package() section:
Traceback (most recent call last): File "setup.py", line 52, in <module> setup( File "/usr/lib/python3.8/site-packages/skbuild/setuptools_wrap.py", line 639, in setup _copy_file(data_file, dest_data_file, hide_listing) File "/usr/lib/python3.8/site-packages/skbuild/setuptools_wrap.py", line 828, in _copy_file copyfile(src_file, dest_file) File "/usr/lib/python3.8/shutil.py", line 259, in copyfile with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst: PermissionError: [Errno 13] Permission denied: '_skbuild/linux-x86_64-3.8/ cmake-install/src/third-party/headers/muparserx/.git/objects/pack/pack- bcece967ee9ec3297e6c8709d2c6d670ad7e3af2.idx'
However, if I execute python setup.py install --root="test-install" -- optimize=1 --skip-build manually I cannot replicate the error.
Is there any difference between when makepkg executes that command and when I do it myself?
Well, makepkg runs under fakeroot. But forget about that. Why is setup.py install attempting to install the .git/ directory of a git repository? -- Eli Schwartz Bug Wrangler and Trusted User
Well, makepkg runs under fakeroot.
But forget about that. Why is setup.py install attempting to install the .git/ directory of a git repository?
Yeah, I was also surprised about that. I need to check carefully the changes from previous version to current one: https://github.com/Qiskit/qiskit-aer/compare/0.3.4...0.4.0 I will have a look tomorrow. All those files src/third-party/headers/muparserx/ weren't in previous versions. I guess the issue has something to do with this commit: https://github.com/Qiskit/qiskit-aer/commit/ b583392338011da93c98a4f86ba149941b78482c#diff-77bd54e19b398c8c948a0b961697d68d where they changed the function get_muparserx_source_code(). Best wishes, Iyán
On 07-02-2020 00:55, Iyán Méndez Veiga wrote:
Well, makepkg runs under fakeroot.
But forget about that. Why is setup.py install attempting to install the .git/ directory of a git repository?
Yeah, I was also surprised about that. I need to check carefully the changes from previous version to current one:
https://github.com/Qiskit/qiskit-aer/compare/0.3.4...0.4.0
I will have a look tomorrow. All those files src/third-party/headers/muparserx/ weren't in previous versions.
I guess the issue has something to do with this commit:
https://github.com/Qiskit/qiskit-aer/commit/ b583392338011da93c98a4f86ba149941b78482c#diff-77bd54e19b398c8c948a0b961697d68d
where they changed the function get_muparserx_source_code().
Best wishes, Iyán
https://github.com/Qiskit/qiskit-aer/commit/d445d0136f61523281fc22f9e20be9c0... looks relevant. There's a muparserx package in aur, https://aur.archlinux.org/packages/muparserx . Try building with that as makedepend or depend ? LW
https://github.com/Qiskit/qiskit-aer/commit/d445d0136f61523281fc22f9e20be9c0 16e1dd8e looks relevant.
There's a muparserx package in aur, https://aur.archlinux.org/packages/muparserx .
Try building with that as makedepend or depend ?
Just tried, and still same error. Even if muparserx is installed, it still clones the repo during the python setup.py build.
I think their cmake files are a bit chaotic for the moment. I have created an issue upstream and add a patch to the PKGBUILD so it generates the package without the .git directories. https://aur.archlinux.org/cgit/aur.git/tree/cmake.patch?h=python-qiskit-aer Now I would like to get rid of the package contains reference to $srcdir warnings. Any ideas? They are all .so files, and using strings I find there are always mentions to .pyx and .cxx files using the full path. Best wishes, Iyán
On 2/7/20 4:36 PM, Iyán Méndez Veiga wrote:
Now I would like to get rid of the package contains reference to $srcdir warnings. Any ideas?
They are all .so files, and using strings I find there are always mentions to .pyx and .cxx files using the full path.
cmake embeds full paths into binaries. -- Eli Schwartz Bug Wrangler and Trusted User
participants (3)
-
Eli Schwartz
-
Iyán Méndez Veiga
-
Lone_Wolf