Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

try_run() causes cmake error in cross-compiling mode #4298

Open
1 task done
Cheney-W opened this issue Jan 26, 2024 · 0 comments
Open
1 task done

try_run() causes cmake error in cross-compiling mode #4298

Cheney-W opened this issue Jan 26, 2024 · 0 comments
Labels
triage Issue pending classification

Comments

@Cheney-W
Copy link

Is there an already existing issue for this?

  • I have searched the existing issues

Expected behavior

No error.

Current behavior

CMake Error: try_run() invoked in cross-compiling mode, please set the following cache variables appropriately:
SM_RUN_RESULT (advanced)
SM_RUN_RESULT__TRYRUN_OUTPUT (advanced)

Steps to reproduce

  1. git clone https://github.com/Cheney-W/vcpkg.git
  2. git checkout Dev/Cheney/36368
  3. .\bootstrap-vcpkg.bat
  4. .\vcpkg.exe install fastrtps:arm64-windows

Fast DDS version/commit

https://github.com/eProsima/Fast-DDS/releases/tag/v2.13.1

Platform/Architecture

Windows 10 Visual Studio 2019

Transport layer

Default configuration, UDPv4 & SHM

Additional context

After add below codes into the https://github.com/eProsima/Fast-DDS/blob/master/src/cpp/CMakeLists.txt:

set(SM_RUN_RESULT 0 CACHE INTERNAL "")
set(SM_RUN_RESULT__TRYRUN_OUTPUT "" CACHE INTERNAL "")

cmake failed with a new error:

CMake Error at src/cpp/CMakeLists.txt:420 (string):
  string sub-command STRIP requires two arguments

The issue is that after executing the try_run command, the value of RUN_OUTPUT_VARIABLE is empty.

XML configuration file

No response

Relevant log output

No response

Network traffic capture

No response

@Cheney-W Cheney-W added the triage Issue pending classification label Jan 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage Issue pending classification
Projects
None yet
Development

No branches or pull requests

1 participant