-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
[xlnt] find_package failure #12107
Comments
I get the same behavior, I also tried The CMake output is as follows:
|
@johnco3 This is an upstream xlnt cmake problem as I tried using upstream repo as a submodule and the result is the same. In the end, I settled for MSBuild. Originally I wanted to open an upstream issue but haven't got to it yet. |
it is frustrating, as it is the only part of my build dependency that
fails. I was digging into the root of the problem and from what I can tell
it is to do with a generated line of cmake code
`set_and_check(XLNT_INCLUDE_DIR "include")`. I don't know where this
originated from as i'm not very familiar with creating portiles for vcpkg.
But it more than likely is called via configure_package_config_file()
called through some `XlntConfig.cmake.in` file which I found on github.
Looks like the problem has to do with expanding the
@XLNT_INCLUDE_INSTALL_DIR@ whatever that is supposed to be.
set(XLNT_VERSION "@xlnt_VERSION@")
@PACKAGE_INIT@
get_filename_component(XLNT_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
set_and_check(XLNT_INCLUDE_DIR "@XLNT_INCLUDE_INSTALL_DIR@")
check_required_components(xlnt)
if(NOT TARGET xlnt::xlnt)
include("${XLNT_CMAKE_DIR}/XlntTargets.cmake")
endif()
This in turn generates the port file (which incidentally has a different
version compared to the code's 1.4.0 which I saw somewhere else).
set(XLNT_VERSION "1.5.0")
####### Expanded from @PACKAGE_INIT@ by configure_package_config_file()
#######
####### Any changes to this file will be overwritten by the next CMake run
####
####### The input file was XlntConfig.cmake.in
########
get_filename_component(PACKAGE_PREFIX_DIR
"${CMAKE_CURRENT_LIST_DIR}/../../" ABSOLUTE)
macro(set_and_check _var _file)
set(${_var} "${_file}")
if(NOT EXISTS "${_file}")
message(FATAL_ERROR "File or directory ${_file} referenced by variable
${_var} does not exist !")
endif()
endmacro()
macro(check_required_components _NAME)
foreach(comp ${${_NAME}_FIND_COMPONENTS})
if(NOT ${_NAME}_${comp}_FOUND)
if(${_NAME}_FIND_REQUIRED_${comp})
set(${_NAME}_FOUND FALSE)
endif()
endif()
endforeach()
endmacro()
####################################################################################
get_filename_component(XLNT_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
set_and_check(XLNT_INCLUDE_DIR "include")
check_required_components(xlnt)
if(NOT TARGET xlnt::xlnt)
include("${XLNT_CMAKE_DIR}/XlntTargets.cmake")
endif()
…On Thu, Jul 9, 2020 at 8:25 AM ZeeWanderer ***@***.***> wrote:
@johnco3 <https:/johnco3> This is an upstream xlnt cmake
problem as I tried using upstream repo as a submodule and the result is the
same. In the end, I settled for MSBuild. Originally I wanted to open an
upstream issue but never got to it yet.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#12107 (comment)>,
or unsubscribe
<https:/notifications/unsubscribe-auth/ABTGRYB5ICK4ZSP37DXHULDR2WZNFANCNFSM4OIKA3JA>
.
|
meet the same problem. how to use xInt.... 1)Cmake erro at **CMake Error at third-party/libstudxml.build/CMakeLists.txt:52 (add_library): CMake Error at third-party/libstudxml.build/CMakeLists.txt:52 (add_library): the 52 is below I can't understand what it means.................. 2)vcpkg erro .. Computing installation plan... wanted help.........Thanks |
Describe the bug
After vcpkg install and integration using
find_package(xlnt CONFIG REQUIRED)
in a cmake project results inEnvironment
To Reproduce
Steps to reproduce the behavior:
find_package(xlnt CONFIG REQUIRED)
in a cmake projectThe text was updated successfully, but these errors were encountered: