xmake-io / xmake

🔥 A cross-platform build utility based on Lua
https://xmake.io
Apache License 2.0
10.14k stars 782 forks source link

升级 xmake 后,包构建失败:package(nlohmann-json): links not found! #5357

Closed ivanallen closed 4 months ago

ivanallen commented 4 months ago

Xmake 版本

xmake v2.9.3+dev.22df8e0, A cross-platform build utility based on Lua

操作系统版本和架构

Linux 10-16-43-32 5.14.0-70.13.1.el9_0.x86_64 #1 SMP PREEMPT Wed May 25 21:01:57 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

描述问题

升级前的版本:xmake v2.8.3+dev.f374224, A cross-platform build utility based on Lua 升级后的版本:xmake v2.9.3+dev.22df8e0, A cross-platform build utility based on Lua

升级 xmake 后,package 构建失败

期待的结果

能正确构建包,或者有 workaround 方法。

工程配置

package("nlohmann-json")

    set_homepage("https://nlohmann.github.io/json/")
    set_description("JSON for Modern C++")
    set_license("MIT")

    add_urls("git@github.xxx.com:ceph/nlohmann-json.git")
    add_versions("v3.11.3", "9cca280a4d0ccf0c08f47a99aa71d1b0e52f8d03")
    add_deps("cmake")

    on_install(function (package)
        local configs = {"-DJSON_BuildTests=OFF"}
        import("package.tools.cmake").install(package, configs)
    end)

    on_test(function (package)
        assert(package:check_cxxsnippets({test = [[
            using json = nlohmann::json;
            void test() {
                json data;
                data["name"] = "world";
            }
        ]]}, {configs = {languages = "c++11"}, includes = {"nlohmann/json.hpp"}}))
    end)

附加信息和错误日志

checking for platform ... linux
checking for architecture ... x86_64
checking for gcc ... /opt/rh/gcc-toolset-12/root/usr/bin/gcc
checkinfo: cannot runv(zig version), No such file or directory
checking for zig ... no
checkinfo: cannot runv(zig version), No such file or directory
checking for zig ... no
checkinfo: cannot runv(nim --version), No such file or directory
checking for nim ... no
checkinfo: cannot runv(nim --version), No such file or directory
checking for nim ... no
configure
{
    plat = linux
    buildir = build
    ndk_stdcxx = true
    mode = release
    ccache = true
    kind = static
    arch = x86_64
    host = linux
    clean = true
}
checking for unzip ... /usr/bin/unzip
checking for git ... /usr/bin/git
checking for gzip ... /usr/bin/gzip
checking for tar ... /usr/bin/tar
updating repositories ..
pulling repository(xsky-repo): git@github.xsky.com:ceph/xmake-repo.git to /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/repositories/xsky-repo ..
/usr/bin/git -c core.fsmonitor=false pull origin -f
Warning: Permanently added 'github.xsky.com' (ECDSA) to the list of known hosts.
Already up to date.
pulling repository(xsky-build-artifacts): git@github.xsky.com:ceph/xmake-build-artifacts.git to /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/repositories/xsky-build-artifacts ..
/usr/bin/git -c core.fsmonitor=false pull origin -f
Warning: Permanently added 'github.xsky.com' (ECDSA) to the list of known hosts.
Already up to date.
pulling repository(build-artifacts): https://gitee.com/xmake-mirror/build-artifacts.git to /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/repositories/build-artifacts ..
/usr/bin/git -c core.fsmonitor=false pull origin main -f
From https://gitee.com/xmake-mirror/build-artifacts
 * branch              main       -> FETCH_HEAD
Already up to date.
pulling repository(xmake-repo): https://gitee.com/tboox/xmake-repo.git to /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/repositories/xmake-repo ..
/usr/bin/git -c core.fsmonitor=false pull origin master -f
From https://gitee.com/tboox/xmake-repo
 * branch              master     -> FETCH_HEAD
Already up to date.
ok
/usr/bin/git rev-parse HEAD
/usr/bin/git rev-parse HEAD
checking for cmake ... no
checkinfo: @programdir/core/sandbox/modules/os.lua:264: cannot runv(ping -c 1 -W 1 127.0.0.1), No such file or directory
stack traceback:
    [C]: in function 'error'
    [@programdir/core/base/os.lua:973]:
    [@programdir/core/sandbox/modules/os.lua:264]: in function 'run'
    [@programdir/modules/detect/tools/find_ping.lua:41]:
    [C]: in function 'xpcall'
    [@programdir/core/base/utils.lua:275]:
    [.../core/sandbox/modules/import/lib/detect/find_program.lua:65]: in function '_do_check'
    [.../core/sandbox/modules/import/lib/detect/find_program.lua:88]: in function '_check'
    [.../core/sandbox/modules/import/lib/detect/find_program.lua:242]: in function '_find'
    [.../core/sandbox/modules/import/lib/detect/find_program.lua:328]:
    [@programdir/modules/lib/detect/find_tool.lua:31]: in function '_find_from_modules'
    [@programdir/modules/lib/detect/find_tool.lua:42]: in function '_find_tool'
    [@programdir/modules/lib/detect/find_tool.lua:88]:
    [@programdir/modules/net/ping.lua:60]:
    [@programdir/modules/net/fasturl.lua:48]: in function 'sort'
    [...modules/private/action/require/impl/install_packages.lua:47]: in function '_sort_packages_urls'
    [...modules/private/action/require/impl/install_packages.lua:794]:
    [@programdir/modules/private/action/require/install.lua:85]:
    [@programdir/actions/require/main.lua:141]:
    [C]: in function 'xpcall'
    [@programdir/core/base/utils.lua:275]:
    [@programdir/core/base/task.lua:491]: in function 'run'
    [@programdir/core/main.lua:327]: in function 'cotask'
    [@programdir/core/base/scheduler.lua:406]:

checking for ping ... no
/usr/bin/git -c core.fsmonitor=false clean -d -f -x
Removing build_b5ca1187/
/usr/bin/git -c core.fsmonitor=false reset --hard
HEAD is now at 9cca280a JSON for Modern C++ 3.11.3 (#4222)
checking for gcc ... /opt/rh/gcc-toolset-12/root/usr/bin/gcc
checking for the c compiler (cc) ... gcc
checking for gcc ... /opt/rh/gcc-toolset-12/root/usr/bin/gcc
checking for the c++ compiler (cxx) ... gcc
checking for cmake ... /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/c/cmake/3.29.2/c093867d5a85460b8d0b71eca73aaba7/bin/cmake
/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/c/cmake/3.29.2/c093867d5a85460b8d0b71eca73aaba7/bin/cmake -DJSON_BuildTests=OFF -DCMAKE_INSTALL_PREFIX=/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97 -DCMAKE_INSTALL_LIBDIR:PATH=lib -G "Unix Makefiles" -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_STATIC_LINKER_FLAGS_RELEASE= -DCMAKE_SHARED_LINKER_FLAGS_RELEASE= "-DCMAKE_CXX_FLAGS_RELEASE= -O3 -DNDEBUG" -DCMAKE_EXE_LINKER_FLAGS_RELEASE= "-DCMAKE_C_FLAGS_RELEASE= -O3 -DNDEBUG" /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json
-- The CXX compiler identification is GNU 12.2.1
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /opt/rh/gcc-toolset-12/root/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Using the multi-header code from /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/include/
-- Configuring done (0.3s)
-- Generating done (0.0s)
CMake Warning:
  Manually-specified variables were not used by the project:

    CMAKE_C_FLAGS_RELEASE

-- Build files have been written to: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187
make -j34 VERBOSE=1
/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/c/cmake/3.29.2/c093867d5a85460b8d0b71eca73aaba7/bin/cmake -S/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json -B/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187 --check-build-system CMakeFiles/Makefile.cmake 0
/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/c/cmake/3.29.2/c093867d5a85460b8d0b71eca73aaba7/bin/cmake -E cmake_progress_start /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187/CMakeFiles /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187//CMakeFiles/progress.marks
make  -f CMakeFiles/Makefile2 all
make[1]: Entering directory '/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187'
make[1]: Nothing to be done for 'all'.
make[1]: Leaving directory '/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187'
/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/c/cmake/3.29.2/c093867d5a85460b8d0b71eca73aaba7/bin/cmake -E cmake_progress_start /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/cache/packages/2407/n/nlohmann-json/v3.11.3/source/nlohmann-json/build_b5ca1187/CMakeFiles 0
make install
Install the project...
-- Install configuration: ""
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/adl_serializer.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/byte_container_with_subtype.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/abi_macros.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/conversions
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/conversions/from_json.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/conversions/to_chars.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/conversions/to_json.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/exceptions.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/hash.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input/binary_reader.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input/input_adapters.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input/lexer.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input/parser.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input/position_t.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/input/json_sax.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators/internal_iterator.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators/iter_impl.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators/iteration_proxy.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators/iterator_traits.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators/json_reverse_iterator.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/iterators/primitive_iterator.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/json_custom_base_class.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/json_pointer.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/json_ref.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/macro_scope.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/macro_unscope.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/call_std
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/call_std/begin.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/call_std/end.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/cpp_future.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/detected.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/identity_tag.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/is_sax.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/std_fs.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/type_traits.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/meta/void_t.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/output
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/output/binary_writer.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/output/output_adapters.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/output/serializer.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/string_concat.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/string_escape.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/detail/value_t.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/json_fwd.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/ordered_map.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/thirdparty
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/thirdparty/hedley
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/thirdparty/hedley/hedley.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/thirdparty/hedley/hedley_undef.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include/nlohmann/json.hpp
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/share/cmake/nlohmann_json/nlohmann_jsonConfig.cmake
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/share/cmake/nlohmann_json/nlohmann_jsonConfigVersion.cmake
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/share/cmake/nlohmann_json/nlohmann_jsonTargets.cmake
-- Installing: /home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/share/pkgconfig/nlohmann_json.pc
finding nlohmann-json from xmake ..
checking for xmake::nlohmann-json ... nlohmann-json v3.11.3
{
  sysincludedirs = {
    "/home/allen/ws/code/xmake-repo/xmake_globaldir/.xmake/packages/n/nlohmann-json/v3.11.3/b5ca1187a9d342bb9d213bacb6abca97/include"
  },
  version = "v3.11.3",
  license = "MIT"
}

error: @programdir/core/package/package.lua:2407: package(nlohmann-json): links not found!
stack traceback:
    [C]: in function 'error'
    [@programdir/core/base/os.lua:973]:
    [@programdir/core/package/package.lua:2407]: in function '_generate_build_configs'
    [@programdir/core/package/package.lua:2571]: in function 'check_cxxsnippets'
    [...en/ws/code/xmake-repo/packages/n/nlohmann-json/xmake.lua:17]: in function 'script'
    [...dir/modules/private/action/require/impl/utils/filter.lua:114]: in function 'call'
    [...dir/modules/private/action/require/impl/actions/test.lua:41]:
    [.../modules/private/action/require/impl/actions/install.lua:444]:

  => install nlohmann-json v3.11.3 .. 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>
error: execv(xmake require -f -y --build -v -D --shallow --extra={configs={shared=false}} nlohmann-json) failed(255)
star-hengxing commented 4 months ago

xmake dev 现在要求所有头文件包都要设置为 headeronly kind

Issues-translate-bot commented 4 months ago

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


xmake dev now requires all header packages to be set to headeronly kind

ivanallen commented 4 months ago

headeronly

可以了。。。

Issues-translate-bot commented 4 months ago

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


headeronly

That's it. . .