xmake-io / xmake-repo

📦 An official xmake package repository
https://xrepo.xmake.io
Apache License 2.0
627 stars 377 forks source link

install openssl 1.1.1-w .. failed #4476

Open lujiex opened 1 month ago

lujiex commented 1 month ago

Xmake 版本

xmake v2.9.3+20240624

操作系统版本和架构

ubuntu20.04

描述问题

image AR命令缺少参数 crs,进入目录加入crs后,make -j8 && make install -j8就正常了 image image image image 虽然我手动编译安装了,但是在项目里面xmake f -a arm还是会重新编译openssl而且还是会报错。

期待的结果

期望能够成功执行。

工程配置

add_rules("mode.debug", "mode.release")

add_requires("crow")

-- set arm toolchain if is_arch("arm") then set_toolchains("arm_toolchain") end

toolchain("arm_toolchain") set_kind("standalone") set_sdkdir("/home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/") toolchain_end()

target("web") set_kind("binary") add_files("src/*.cpp") add_packages("crow")

附加信息和错误日志

/home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/sslbuffertest.d.tmp -MT test/sslbuffertest.o -c -o test/sslbuffertest.o test/sslbuffertest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/sslcorrupttest.d.tmp -MT test/sslcorrupttest.o -c -o test/sslcorrupttest.o test/sslcorrupttest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -I. -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/ssltest_old.d.tmp -MT test/ssltest_old.o -c -o test/ssltest_old.o test/ssltest_old.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/stack_test.d.tmp -MT test/stack_test.o -c -o test/stack_test.o test/stack_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/sysdefaulttest.d.tmp -MT test/sysdefaulttest.o -c -o test/sysdefaulttest.o test/sysdefaulttest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/test_test.d.tmp -MT test/test_test.o -c -o test/test_test.o test/test_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/threadstest.d.tmp -MT test/threadstest.o -c -o test/threadstest.o test/threadstest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/time_offset_test.d.tmp -MT test/time_offset_test.o -c -o test/time_offset_test.o test/time_offset_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/tls13ccstest.d.tmp -MT test/tls13ccstest.o -c -o test/tls13ccstest.o test/tls13ccstest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -I. -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/tls13encryptiontest.d.tmp -MT test/tls13encryptiontest.o -c -o test/tls13encryptiontest.o test/tls13encryptiontest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -I. -Iinclude -Iapps -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/uitest.d.tmp -MT test/uitest.o -c -o test/uitest.o test/uitest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/v3ext.d.tmp -MT test/v3ext.o -c -o test/v3ext.o test/v3ext.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/v3nametest.d.tmp -MT test/v3nametest.o -c -o test/v3nametest.o test/v3nametest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/verify_extra_test.d.tmp -MT test/verify_extra_test.o -c -o test/verify_extra_test.o test/verify_extra_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/versions.d.tmp -MT test/versions.o -c -o test/versions.o test/versions.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/wpackettest.d.tmp -MT test/wpackettest.o -c -o test/wpackettest.o test/wpackettest.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/x509_check_cert_pkey_test.d.tmp -MT test/x509_check_cert_pkey_test.o -c -o test/x509_check_cert_pkey_test.o test/x509_check_cert_pkey_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/x509_dup_cert_test.d.tmp -MT test/x509_dup_cert_test.o -c -o test/x509_dup_cert_test.o test/x509_dup_cert_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -I. -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/x509_internal_test.d.tmp -MT test/x509_internal_test.o -c -o test/x509_internal_test.o test/x509_internal_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/x509_time_test.d.tmp -MT test/x509_time_test.o -c -o test/x509_time_test.o test/x509_time_test.c /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -Iinclude -pthread -Wa,--noexecstack -fPIC -DNDEBUG -MMD -MF test/x509aux.d.tmp -MT test/x509aux.o -c -o test/x509aux.o test/x509aux.c /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \ "-oMakefile" apps/CA.pl.in > "apps/CA.pl" /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \ "-oMakefile" apps/tsget.in > "apps/tsget.pl" /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \ "-oMakefile" tools/c_rehash.in > "tools/c_rehash" /usr/bin/perl "-I." -Mconfigdata "util/dofile.pl" \ "-oMakefile" util/shlib_wrap.sh.in > "util/shlib_wrap.sh" /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc-ar apps/libapps.a apps/app_rand.o apps/apps.o apps/bf_prefix.o apps/opt.o apps/s_cb.o apps/s_socket.o /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-gcc -I. -Iinclude -Icrypto -fPIC -pthread -Wa,--noexecstack -fPIC -DOPENSSL_USE_NODELETE -DOPENSSL_PIC -DOPENSSL_CPUID_OBJ -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DKECCAK1600_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM -DECP_NISTZ256_ASM -DPOLY1305_ASM -DOPENSSLDIR="\"/home/donnel/.xmake/packages/o/openssl/1.1.1-w/d48c7ecdf758487788da8471d8188039\"" -DENGINESDIR="\"/home/donnel/.xmake/packages/o/openssl/1.1.1-w/d48c7ecdf758487788da8471d8188039/lib/engines-1.1\"" -DNDEBUG -c -o crypto/aes/aes-armv4.o crypto/aes/aes-armv4.S /home/donnel/work/hpdu/toolchain/gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/5.5.0/../../../../arm-linux-gnueabihf/bin/ar: two different operation options specified make[1]: [Makefile:676: apps/libapps.a] Error 1 make[1]: Waiting for unfinished jobs.... chmod a+x apps/CA.pl chmod a+x apps/tsget.pl chmod a+x tools/c_rehash chmod a+x util/shlib_wrap.sh make[1]: Leaving directory '/home/donnel/.xmake/cache/packages/2406/o/openssl/1.1.1-w/source' make: *** [Makefile:174: all] Error 2 error: @programdir/core/sandbox/modules/os.lua:378: execv(/usr/bin/make -j18 VERBOSE=1 V=1) failed(2) stack traceback: [C]: in function 'error' [@programdir/core/base/os.lua:973]: [@programdir/core/sandbox/modules/os.lua:378]: [@programdir/core/sandbox/modules/os.lua:291]: in function 'vrunv' [@programdir/modules/package/tools/make.lua:134]: in function 'make' [@programdir/modules/package/tools/make.lua:160]: in function 'build' [...ake/repositories/xmake-repo/packages/o/openssl/xmake.lua:159]: in function 'script' [...dir/modules/private/action/require/impl/utils/filter.lua:114]: in function 'call' [.../modules/private/action/require/impl/actions/install.lua:404]:

=> install openssl 1.1.1-w .. failed error: @programdir/core/main.lua:329: @programdir/modules/async/runjobs.lua:325: .../modules/private/action/require/impl/actions/install.lua:506: install failed! stack traceback: [C]: in function 'error' [@programdir/core/base/os.lua:973]: [.../modules/private/action/require/impl/actions/install.lua:506]: in function 'catch' [@programdir/core/sandbox/modules/try.lua:123]: in function 'try' [.../modules/private/action/require/impl/actions/install.lua:370]: [...modules/private/action/require/impl/install_packages.lua:491]: in function 'jobfunc' [@programdir/modules/async/runjobs.lua:241]:

stack traceback: [C]: in function 'error' @programdir/core/base/os.lua:973: in function 'base/os.raiselevel' (...tail calls...) @programdir/core/main.lua:329: in upvalue 'cotask' @programdir/core/base/scheduler.lua:406: in function <@programdir/core/base/scheduler.lua:399>

waruqi commented 1 month ago

交叉编译,不会从系统上找。。编译错误,可以自己分析下,提个 pr 过来改进包

lujiex commented 1 month ago

我在.xmake/cache/packages/2406/o/openssl/1.1.1-w/source目录,修改了makefile,增加ar参数crs后,直接make -j8 && make install -j8后,安装到了.xmake/packages/o/openssl/1.1.1-w/d48c7ecdf758487788da8471d8188039

Issues-translate-bot commented 1 month ago

Bot detected the issue body's language is not English, translate it automatically.


I modified the makefile in the .xmake/cache/packages/2406/o/openssl/1.1.1-w/source directory. After adding the ar parameter crs, I directly made -j8 && make install -j8 and installed it in .xmake/ packages/o/openssl/1.1.1-w/d48c7ecdf758487788da8471d8188039

lujiex commented 1 month ago

image 但是xrepo还是认为openssl未安装