castor icon indicating copy to clipboard operation
castor copied to clipboard

Compression of binary with UPX failed

Open davidnurdin opened this issue 1 year ago • 1 comments

Hi, Do you have an idea why ?

image

Fatal error: Uncaught PharException: phar "/home/david/poc/castorSampleDoctrine/my-app.linux.x86_64" has a broken signature in /home/david/poc/castorSampleDoctrine/my-app.linux.x86_64:11 Stack trace: #0 /home/david/poc/castorSampleDoctrine/my-app.linux.x86_64(11): Phar::mapPhar('alias.phar') #1 {main} thrown in /home/david/poc/castorSampleDoctrine/my-app.linux.x86_64 on line 11

davidnurdin avatar Sep 11 '24 21:09 davidnurdin

Have you tested your binary before UPX compression? The SPC library Castor uses has built-in UPX support, though it's not currently utilized.

To implement UPX, consider submitting a PR that adds a flag to Castor's compile command. This should execute bin/spc install-pkg upx for installation and run the SPC command with --with-upx-pack.

Remember to include a warning that the UPX installation only works on Linux and Windows, as per SPC documentation. This would ensure a more robust implementation of UPX compression in the project.

tigitz avatar Sep 12 '24 10:09 tigitz

I am going to close here for now due to the lack of feedback. Please let us know when you have more information and we can consider to reopen.

lyrixx avatar Oct 14 '24 12:10 lyrixx