Skip to content

Compiling libfido in macOS bigSur - apple silicon chip. #274

@iradization

Description

@iradization

Hi, I'm trying to compile the libfido project for macOS environment with apple silicon (arm64)

According to the documentation, it should be performed in the following command, but I think there are some prerequisites that are unmentioned ...

This is my attempt

libfido2-1.6.0 % (rm -rf build && mkdir build && cd build && cmake ..)

-- The C compiler identification is AppleClang 12.0.0.12000032
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Checking for one of the modules 'libcbor'
-- Checking for one of the modules 'libcrypto'
-- Looking for include file cbor.h
-- Looking for include file cbor.h - not found
CMake Error at CMakeLists.txt:97 (message):
  could not find cbor header files

from cmake source, I fell on the following code :

        if(NOT CBOR_FOUND)
                check_include_files(cbor.h HAVE_CBOR_H)
                if(NOT HAVE_CBOR_H)
                        message(FATAL_ERROR "could not find cbor header files")
                endif()
                set(CBOR_LIBRARIES "cbor")
        endif()

Not sure where exactly where should I put cbor.h relative to libfido main folder ?
Does it have other pre-requirements besides that ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions