flatpak / flatpak-builder

Tool to build flatpaks from source
GNU Lesser General Public License v2.1
139 stars 91 forks source link

tar jxf and cp -R go crazy #196

Closed user5145 closed 6 years ago

user5145 commented 6 years ago

I tried to learn flatpak and port dofus at the same time and something has happend what I can't understand. It may be my incompetence, but whenever i try to copy adobe sdk 2.6 i get weird logs informing me that cp or tar jxf are compressing my data https://pastebin.com/tS7rYKm6

If I try to use type:archieve then it happens during a cp command. Of course cp and tar jxf work without sandbox.

that's the module https://pastebin.com/G8VYjK2L

The code isn't the best there, but that was only for learning purposes so sorry for that All the code: https://pastebin.com/YPX9LeWK I build it using flatpak-builder --repo=repo --force-clean build-dir org.flatpak.Hello.json

edit: sorry not this command the real one is sudo flatpak-builder --force-clean build-dir org.flatpak.Hello.json

alexlarsson commented 6 years ago

The compression output is not from tar, but from the next step which is stripping and compressing the debug info from the files. Then it fails because its unable to strip a file, maybe it doesn't have write permissions on it?

user5145 commented 6 years ago

It worked with sudo, thanks. I should try it firstly, but i don't remember building it with root privileges previously so I was sure that it is not possible to be so simple and i didn't know that it creates any debug information inside a working directory, I was only aware of cache.

user5145 commented 6 years ago

ok. i wasn't able to fully test it because winepak server was down and i wasn't able to update flatpak applications without removing hundreds of gigs of games. So even if it has permission (644 or/and 777), downloads adobeairsdk instead of copying and creates .flatpak-builder and build-dir by itself it's still failing without sudo and gives Error: module adobe-air: Child process exited with code 1

with sudo it works, though I think it should work without too (should i reopen the issue?). I can recreate it even in a new folder and with json which consist only this one module. Of course i wouldn't bother you with stupid sudo, but things get worse.

after I add tar.xz with libraries copied from my system /usr/lib64 the adobe-air module fails. What's surprising for me though is that without this preceding it module with libraries in a tar file it works (with sudo). If it was because of the module with libraries than it would break during building that adobes-libraries module, but it does after (when it want to copy adobe air)and the message now is Error: module adobe-air: Child process exited with code 139

even if i remove the module with libraries to build the cache and then re enable it it will fail to copy that cache with error code 139

PS that previous tar file from the first post has 644 permissions and i'm the owner so flatpak-builder should be able to copy it. I use arch and flatpak builder 0.99.3

edit: this small module fails with code 1 without sudo and works with sudo https://pastebin.com/jRRk7gst edi2: the second error (139) can be built using this tar https://drive.google.com/file/d/1jt2_J8sp0FgyY4Scts8vkH2lS_dAzmhS/view?usp=sharing and this is a json file https://pastebin.com/taDgtb5x edit3: freedesktop 1.6 gives error code 127 instead of 139 and a message! /bin/sh: relocation error: /app/lib/libc.so.6: symbol _dl_exception_create, version GLIBC_PRIVATE not defined in file ld-linux-x86-64.so.2 with link time reference Error: module adobe-air: Child process exited with code 127 I guess that i cannot just copy the libraries from my system into flatpak and that's why i have that issue. Edit4: it worked without libc.so.6 and libdl.so.2. Could someone explain me why? and 18.08 runtime doesn't report that helpful message, it should be repaired.