Skip to content

Setting up Boost_ARCHITECTURE variable in CMakeLists.txt #225

@smuroff

Description

@smuroff

I've a suggestion to explicitly set up Boost_ARCHITECTURE variable in CMakeLists.txt

if (CMAKE_SYSTEM_PROCESSOR MATCHES "(x86)|(X86)|(amd64)|(AMD64)")
    set(Boost_ARCHITECTURE "-x64")
else()
    set(Boost_ARCHITECTURE "-x32")
endif()

This will allow CMake to find Boost libraries with "-x64" or "-x32" suffixes. (I've compiled both architectures and this helps me to avoid "Unable to find the requested Boost libraries" error).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions