microsoft / vcpkg

C++ Library Manager for Windows, Linux, and MacOS
MIT License
22.74k stars 6.29k forks source link

[openssl] openssl:x64-linux build failed #38729

Closed SivanChan closed 1 month ago

SivanChan commented 3 months ago

Package: openssl:x64-linux@3.3.0#1

Host Environment

To Reproduce

vcpkg install openssl:x64-linux

Failure logs

-- Using cached openssl-openssl-openssl-3.3.0.tar.gz.
-- Cleaning sources at /home/cym/workspace/code/vcpkg/buildtrees/openssl/src/nssl-3.3.0-961d78b8a1.clean. Use --editable to skip cleaning for the packages you specify.
-- Extracting source /home/cym/workspace/code/vcpkg/downloads/openssl-openssl-openssl-3.3.0.tar.gz
-- Applying patch cmake-config.patch
-- Applying patch command-line-length.patch
-- Applying patch script-prefix.patch
-- Applying patch windows/install-layout.patch
-- Applying patch windows/install-pdbs.patch
-- Applying patch unix/android-cc.patch
-- Applying patch unix/move-openssldir.patch
-- Applying patch unix/no-empty-dirs.patch
-- Applying patch unix/no-static-libs-for-shared.patch
-- Using source at /home/cym/workspace/code/vcpkg/buildtrees/openssl/src/nssl-3.3.0-961d78b8a1.clean
openssl requires Linux kernel headers from the system package manager.
   They can be installed on Alpine systems via `apk add linux-headers`.
   They can be installed on Ubuntu systems via `apt install linux-libc-dev`.

-- Getting CMake variables for x64-linux
-- Getting CMake variables for x64-linux-dbg
-- Getting CMake variables for x64-linux-rel
-- Configuring x64-linux-dbg
-- Configuring x64-linux-rel
-- Building x64-linux-dbg
CMake Error at scripts/cmake/vcpkg_execute_build_process.cmake:134 (message):
    Command failed: /usr/bin/make V=1 -j 9 -f Makefile build_sw
    Working Directory: /home/cym/workspace/code/vcpkg/buildtrees/openssl/x64-linux-dbg/
    See logs for more information:
      /home/cym/workspace/code/vcpkg/buildtrees/openssl/build-x64-linux-dbg-out.log
      /home/cym/workspace/code/vcpkg/buildtrees/openssl/build-x64-linux-dbg-err.log

Call Stack (most recent call first):
  scripts/cmake/vcpkg_build_make.cmake:136 (vcpkg_execute_build_process)
  scripts/cmake/vcpkg_install_make.cmake:2 (vcpkg_build_make)
  ports/openssl/unix/portfile.cmake:120 (vcpkg_install_make)
  ports/openssl/portfile.cmake:71 (include)
  scripts/ports.cmake:175 (include)
/home/cym/workspace/code/vcpkg/buildtrees/openssl/build-x64-linux-dbg-err.log ``` Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl": Permission denied make: *** [Makefile:4400:include/openssl/asn1t.h] 错误 25 make: *** 正在等待未完成的任务.... Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl": Permission denied make: *** [Makefile:4398:include/openssl/asn1.h] 错误 25 Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl": Permission denied make: *** [Makefile:4402:include/openssl/bio.h] 错误 25 Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/mkinstallvars.pl": Permission denied make: *** [Makefile:4376:builddata.pm] 错误 25 Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/mkinstallvars.pl": Permission denied make: *** [Makefile:4384:installdata.pm] 错误 25 Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl": Permission denied make: *** [Makefile:4394:include/crypto/dso_conf.h] 错误 25 Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl": Permission denied make: *** [Makefile:4392:include/crypto/bn_conf.h] 错误 25 Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl": Permission denied make: *** [Makefile:4378:crypto/params_idx.c] 错误 25 ```
/home/cym/workspace/code/vcpkg/buildtrees/openssl/build-x64-linux-dbg-out.log ``` /usr/bin/perl ../src/nssl-3.3.0-961d78b8a1.clean/util/mkinstallvars.pl PREFIX=. BINDIR=apps LIBDIR= INCLUDEDIR=include APPLINKDIR=ms ENGINESDIR=engines MODULESDIR=providers "VERSION=3.3.0" "LDLIBS=-ldl -pthread " > builddata.pm /usr/bin/perl "-I." "-I../src/nssl-3.3.0-961d78b8a1.clean/util/perl" "-Mconfigdata" "-MOpenSSL::paramnames" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/crypto/params_idx.c.in > crypto/params_idx.c /usr/bin/perl ../src/nssl-3.3.0-961d78b8a1.clean/util/mkinstallvars.pl "PREFIX=/home/cym/workspace/code/vcpkg/installed/x64-linux/debug" BINDIR=bin "LIBDIR=lib" INCLUDEDIR=include APPLINKDIR=include/openssl "ENGINESDIR=/home/cym/workspace/code/vcpkg/installed/x64-linux/debug/lib/engines-3" "MODULESDIR=/home/cym/workspace/code/vcpkg/installed/x64-linux/debug/lib/ossl-modules" "PKGCONFIGDIR=/home/cym/workspace/code/vcpkg/installed/x64-linux/debug/lib/pkgconfig" "CMAKECONFIGDIR=/home/cym/workspace/code/vcpkg/installed/x64-linux/debug/share/openssl" "LDLIBS=-ldl -pthread " "VERSION=3.3.0" > installdata.pm /usr/bin/perl "-I." "-Mconfigdata" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/include/crypto/bn_conf.h.in > include/crypto/bn_conf.h /usr/bin/perl "-I." "-Mconfigdata" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/include/crypto/dso_conf.h.in > include/crypto/dso_conf.h /usr/bin/perl "-I." "-I../src/nssl-3.3.0-961d78b8a1.clean/util/perl" "-Mconfigdata" "-MOpenSSL::paramnames" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/include/internal/param_names.h.in > include/internal/param_names.h /usr/bin/perl "-I." "-Mconfigdata" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/include/openssl/asn1.h.in > include/openssl/asn1.h /usr/bin/perl "-I." "-Mconfigdata" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/include/openssl/asn1t.h.in > include/openssl/asn1t.h /usr/bin/perl "-I." "-Mconfigdata" "../src/nssl-3.3.0-961d78b8a1.clean/util/dofile.pl" "-oMakefile" ../src/nssl-3.3.0-961d78b8a1.clean/include/openssl/bio.h.in > include/openssl/bio.h ```
Wrl233 commented 3 months ago

I also encountered the same problem,but my operating system is Winodws11.

FrankXie05 commented 3 months ago

Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/mkinstallvars.pl": Permission denied

@Wrl233 Thanks for posting this issue, you can try to run the command with administrator rights.

Ndaruga commented 3 months ago

On Mac Os, I did solve this by installing pkg-config using homebrew

brew install pkg-config

then I rerun the install command using admin privileges.

IronsDu commented 3 months ago

I can't install openssl under WSL too, the build-x64-linux-dbg-err.log is:

ln: ./apps: cannot overwrite directory
make[1]: *** [Makefile:4197: apps/openssl.cnf] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:2297: build_sw] Error 2
dg0yt commented 3 months ago

Three other issues thrown on one original issue. Not helpful.

github-actions[bot] commented 2 months ago

This is an automated message. Per our repo policy, stale issues get closed if there has been no activity in the past 28 days. The issue will be automatically closed in 14 days. If you wish to keep this issue open, please add a new comment.

poisonousfire commented 2 months ago

Can't execute perl script "../src/nssl-3.3.0-961d78b8a1.clean/util/mkinstallvars.pl": Permission denied

@Wrl233 Thanks for posting this issue, you can try to run the command with administrator rights. I ran into the same problem on ubuntu. Usingsudo ./vcpkg install openssl:x64-linuxdoes not work,dofile.pl and mkinstallvars.plpermissions are 644, please help me

dg0yt commented 2 months ago

Usingsudo ./vcpkg install openssl:x64-linuxdoes not work

Don't run sudo vcpkg. Don't run sudo vcpkg. Don't run sudo vcpkg.

dofile.pl and mkinstallvars.plpermissions are 644, please help me

Is this also on WSL?

poisonousfire commented 2 months ago

Usingsudo ./vcpkg install openssl:x64-linuxdoes not work

Don't run sudo vcpkg. Don't run sudo vcpkg. Don't run sudo vcpkg.

dofile.pl and mkinstallvars.plpermissions are 644, please help me

Is this also on WSL?

No, it's based on ubuntu

dg0yt commented 2 months ago

WSL is just a virtual environment for running linux in windows. It can be used with Ubuntu.

poisonousfire commented 2 months ago

WSL is just a virtual environment for running linux in windows. It can be used with Ubuntu.

I use kylin system, which is based on ubuntu, and I ran into this problem on this system

FrankXie05 commented 1 month ago

This issue hasn’t been updated for a long time; if it is still an issue, please ping me and I will reopen this issue.

IronsDu commented 1 month ago

This issue hasn’t been updated for a long time; if it is still an issue, please ping me and I will reopen this issue.

问题都没解决,关闭它干嘛。 问题如果已经解决,提issue的人会自己来关闭的。

sfhacker commented 1 month ago

Embarrassing!