Skip to content

Commit 6be98a9

Browse files
laurencelundbladeLaurence Lundblade
andauthored
Update build instructions and floating-point documentation
Describes the build instructions for CMake better. A lot of the build instructions were for float, so that section got reworked too. The float concept stuff was moved into the Numbers document out of the header files because it is for both encoding and decoding. * Update the build instructions * Update the build instructions * Lots of text updating * Float and build documentation update * Last merge went wrong --------- Co-authored-by: Laurence Lundblade <lgl@securitytheory.com>
1 parent 1f638d3 commit 6be98a9

File tree

5 files changed

+466
-294
lines changed

5 files changed

+466
-294
lines changed

CMakeLists.txt

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,21 @@ option(QCBOR_DISABLE_INDEFINITE_LENGTH_ARRAYS "Disable encoding and decoding of
4141
option(QCBOR_DISABLE_DECODE_CONFORMANCE "Exclude all decode conformance checking features" OFF)
4242
option(USEFULBUF_DISABLE_STREAMING "Exclude features for streaming encoding" OFF)
4343

44+
# This is backwards compatibility for float-related cmake options -- decided
45+
# to just make the cmake option the same as the #define
46+
if(DEFINED QCBOR_OPT_DISABLE_PREFERRED_FLOAT)
47+
set(QCBOR_DISABLE_PREFERRED_FLOAT ${QCBOR_OPT_DISABLE_PREFERRED_FLOAT} CACHE BOOL "xx" FORCE)
48+
endif()
49+
50+
if(DEFINED QCBOR_OPT_DISABLE_ALL_FLOAT)
51+
set(USEFULBUF_DISABLE_ALL_FLOAT ${QCBOR_OPT_DISABLE_ALL_FLOAT} CACHE BOOL "xx" FORCE)
52+
endif()
53+
54+
if(DEFINED QCBOR_OPT_DISABLE_FLOAT_HW_USE)
55+
set(QCBOR_DISABLE_FLOAT_HW_USE ${QCBOR_OPT_DISABLE_FLOAT_HW_USE} CACHE BOOL "xx" FORCE)
56+
endif()
57+
58+
4459
if (BUILD_QCBOR_WARN)
4560
# Compile options applying to all targets in current directory and below
4661
add_compile_options(-Wall -Wextra -Wpedantic -Wshadow -Wconversion -Wcast-qual)

0 commit comments

Comments
 (0)