Browse Source

CMake improvements.

- Begin adding options to enable/disable different features.
- Increase minimum CMake version to 3.2.
- Support installation of the built files.
- Add checks for necessary include files, functions etc.
- Generate options.h and config.h.
- Use GNUInstallDirs to support installation, which is designed to be somewhat
  cross-platform.
- Export wolfssl CMake target during installation, so others using CMake can
  link against wolfssl easily.
- Disallow in-source builds.
- Place the generation of BUILD_* flags (controlled with AM_CONDITIONALs
  in configure.ac) in a separate function in functions.cmake,
  generate_build_flags.
- Implement the logic to conditionally add source files from
  src/include.am in a function in functions.cmake, generate_lib_src_list.
- Exclude tls_bench from Windows. Doesn't compile with MSVC. WIP.
- Update INSTALL with latest CMake build instructions.
- Add a cmake/include.am to ensure CMake files get added to the distribution.
Hayden Roche 3 years ago
parent
commit
8f6c21d600
7 changed files with 2213 additions and 137 deletions
  1. 1 0
      .gitignore
  2. 1254 111
      CMakeLists.txt
  3. 58 26
      INSTALL
  4. 1 0
      Makefile.am
  5. 54 0
      cmake/config.in
  6. 843 0
      cmake/functions.cmake
  7. 2 0
      cmake/include.am

+ 1 - 0
.gitignore

@@ -12,6 +12,7 @@ ctaocrypt/src/src/
 *.user
 configure
 config.*
+!cmake/config.in
 *Debug/
 *Release/
 *.ncb

File diff suppressed because it is too large
+ 1254 - 111
CMakeLists.txt


+ 58 - 26
INSTALL

@@ -78,29 +78,61 @@
     http://www.wolfssl.com/yaSSL/Docs-cyassl-manual-2-building-cyassl.html
 
 14. Building with CMake
-    Note: Primary development uses automake (./configure). The support for CMake is minimal.
-
-    Internally cmake is setup to do the following:
-    1. Uses the ./configure generated wolfssl/options.h as the build options by coping it to the build directory as user_settings.h.
-    2. Builds wolfSSL as library.
-    3. Builds the examples.
-
-    Build Steps:
-    $ mkdir build
-    $ cd build
-    $ cmake ..
-    $ cmake --build .
-    $ cmake --install .
-
-    To build library only and not build examples and test apps use:
-    $ cmake .. -DBUILD_TESTS=NO
-
-    To build with debugging use:
-    $ cmake .. -DCMAKE_BUILD_TYPE=Debug
-
-    Make sure and run the built examples and test from the wolfssl-root to properly find the ./certs directory.
-
-    CMake on Windows with Visual Studio
-    1. Open Command Prompt
-    2. Run the Visual Studio batch to setup command line variables: Example: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvars64.bat
-    3. Then use steps above
+    Note: Primary development uses automake (./configure). The support for CMake
+    is still under development.
+
+    For configuring wolfssl using CMake, we recommend downloading the CMake
+    GUI (https://cmake.org/download/). This tool allows you to see all of
+    wolfssl's configuration variables, set them, and view their descriptions.
+    Looking at the GUI or CMakeCache.txt (generated after running cmake once) is
+    the best way to find out what configuration options are available and what
+    they do. You can also invoke CMake from the GUI, which is described in the
+    Windows instructions below. For Unix-based systems, we describe the command
+    line work flow. Regardless of your chosen workflow, cmake will generate
+    a header options.h in the wolfssl directory that contains the options used
+    to configure the build.
+
+    Unix-based Platforms
+    ---
+    1) Navigate to the wolfssl root directory containing "CMakeLists.txt".
+    2) Create a directory called "build" and change into it. This is where
+       CMake will store build files.
+    3) Run `cmake ..` to generate the target build files (e.g. UNIX Makefiles).
+       To enable or disable features, set them using -D<option>=[yes/no]. For
+       example, to disable TLS 1.3 support, run cmake .. -DWOLFSSL_TLS13=no
+       (autoconf equivalent: ./configure --disable-tls13) To enable DSA, run
+       cmake .. -DWOLFSSL_DSA=yes (autoconf equivalent: ./configure
+       --enable-dsa). Again, you can find a list of these options and their
+       descriptions either using the CMake GUI or by looking at CMakeCache.txt.
+    5) The build directory should now contain the generated build files. Build
+       with `cmake --build .`. Under the hood, this runs the target build tool
+       (by default, make). You can also invoke the target build tool directly
+       (e.g. make).
+
+       To build with debugging use: `cmake .. -DCMAKE_BUILD_TYPE=Debug`.
+
+    Windows (Visual Studio)
+    ---
+    1) Go to this page, download the appropriate Windows installer, and install
+       to get the CMake GUI: https://cmake.org/download/ Native CMake support in
+       Visual Studio 16 2019 (and possibly older versions) has proven buggy. We
+       recommend using the CMake GUI in concert with Visual Studio, as described
+    in these steps.
+    2) Open CMake.
+    3) Where is the soure code: <root directory of wolfssl containing
+       CMakeLists.txt>
+    4) Where to build the binaries: <build directory, e.g. wolfssl/build>
+    5) Hit Configure. CMake runs the code in CMakeLists.txt and builds up an
+       internal representation of the project.
+    6) Hit Generate. CMake generates the build files. For Windows, this will
+       be Visual Studio project (.vcxproj) and solution (.sln) files.
+    7) Open Visual Studio and select "Open a project or solution".
+    8) Navigate to the build directory and select wolfssl.sln to load the
+       project.
+
+    Windows (command line)
+    ---
+    1) Open Command Prompt
+    2) Run the Visual Studio batch to setup command line variables, e.g. C:\Program Files (x86)\Microsoft Visual   
+       Studio\2017\Community\VC\Auxiliary\Build\vcvars64.bat
+    3) Follow steps in "Unix-based Platforms" above.

+ 1 - 0
Makefile.am

@@ -152,6 +152,7 @@ EXTRA_DIST+= LPCExpresso.project
 EXTRA_DIST+= resource.h wolfssl.rc
 EXTRA_DIST+= CMakeLists.txt
 
+include cmake/include.am
 include wrapper/include.am
 include cyassl/include.am
 include wolfssl/include.am

+ 54 - 0
cmake/config.in

@@ -0,0 +1,54 @@
+/* Define to 1 if you have the <arpa/inet.h> header file. */
+#cmakedefine HAVE_ARPA_INET_H @HAVE_ARPA_INET_H@
+
+/* Define to 1 if you have the <sys/socket.h> header file. */
+#cmakedefine HAVE_SYS_SOCKET_H @HAVE_SYS_SOCKET_H@
+
+/* Define to 1 if you have the <errno.h> header file. */
+#cmakedefine HAVE_ERRNO_H @HAVE_ERRNO_H@
+
+/* Define to 1 if you have the `getaddrinfo' function. */
+#cmakedefine HAVE_GETADDRINFO @HAVE_GETADDRINFO@
+
+/* Define to 1 if you have the `gmtime_r' function. */
+#cmakedefine HAVE_GMTIME_R @HAVE_GMTIME_R@
+
+/* Define to 1 if you have the <limits.h> header file. */
+#cmakedefine HAVE_LIMITS_H @HAVE_LIMITS_H@
+
+/* Define to 1 if you have the <pcap/pcap.h> header file. */
+#cmakedefine HAVE_PCAP_PCAP_H @HAVE_PCAP_PCAP_H@
+
+/* Define if you have POSIX threads libraries and header files. */
+#cmakedefine HAVE_PTHREAD @HAVE_PTHREAD@
+
+/* Define to 1 if you have the `strftime' function. */
+#cmakedefine HAVE_STRFTIME @HAVE_STRFTIME@
+
+/* Define to 1 if you have the <strings.h> header file. */
+#cmakedefine HAVE_STRINGS_H @HAVE_STRINGS_H@
+
+/* Define to 1 if you have the <string.h> header file. */
+#cmakedefine HAVE_STRING_H @HAVE_STRING_H@
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#cmakedefine HAVE_SYS_TIME_H @HAVE_SYS_TIME_H@
+
+/* Define to 1 if the system has the type `__uint128_t'. */
+#cmakedefine HAVE___UINT128_T @HAVE___UINT128_T@
+
+/* Define to the full name of this package. */
+#define PACKAGE_NAME "@CMAKE_PROJECT_NAME@"
+
+/* The size of `long', as computed by sizeof. */
+#cmakedefine SIZEOF_LONG @SIZEOF_LONG@
+
+/* The size of `long long', as computed by sizeof. */
+#cmakedefine SIZEOF_LONG_LONG @SIZEOF_LONG_LONG@
+
+/* The size of `time_t', as computed by sizeof. */
+#cmakedefine SIZEOF_TIME_T @SIZEOF_TIME_T@
+
+/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
+   significant byte first (like Motorola and SPARC, unlike Intel). */
+#cmakedefine WORDS_BIGENDIAN

+ 843 - 0
cmake/functions.cmake

@@ -0,0 +1,843 @@
+function(override_cache VAR VAL)
+    get_property(VAR_TYPE CACHE ${VAR} PROPERTY TYPE)
+    set(${VAR} ${VAL} CACHE ${VAR_TYPE} ${${VAR}_HELP_STRING} FORCE)
+endfunction()
+
+function(generate_build_flags)
+    set(BUILD_DISTRO ${WOLFSSL_DISTRO} PARENT_SCOPE)
+    set(BUILD_ALL ${WOLFSSL_ALL} PARENT_SCOPE)
+    if(WOLFSSL_TLS13 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_TLS13 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_RNG OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_RNG "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SCTP OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SCTP "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_MCAST ${WOLFSSL_MCAST} PARENT_SCOPE)
+    set(BUILD_IPV6 ${WOLFSSL_IPV6} PARENT_SCOPE)
+    set(BUILD_LEAN_PSK ${WOLFSSL_LEAN_PSK} PARENT_SCOPE)
+    set(BUILD_LEAN_TLS ${WOLFSSL_LEAN_TLS} PARENT_SCOPE)
+    set(BUILD_LOWMEM ${WOLFSSL_LOWRESOURCE} PARENT_SCOPE)
+    set(BUILD_PKCALLBACKS ${WOLFSSL_PKCALLBACKS} PARENT_SCOPE)
+    set(BUILD_CRYPTOAUTHLIB ${WOLFSSL_CRYPTOAUTHLIB} PARENT_SCOPE)
+    if(WOLFSSL_SNIFFER OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SNIFFER "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_SNIFFTEST ${WOLFSSL_SNIFFTEST} PARENT_SCOPE)
+    if(WOLFSSL_AESGCM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_AESGCM "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_AESCCM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_AESCCM "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_ARM_ASM ${WOLFSSL_ARM_ASM} PARENT_SCOPE)
+    set(BUILD_XILINX ${WOLFSSL_XILINX} PARENT_SCOPE)
+    set(BUILD_AESNI ${WOLFSSL_AESNI} PARENT_SCOPE)
+    set(BUILD_INTEL_ASM ${WOLFSSL_INTEL_ASM} PARENT_SCOPE)
+    set(BUILD_AFALG ${WOLFSSL_AFALG} PARENT_SCOPE)
+    set(BUILD_DEVCRYPTO ${WOLFSSL_DEVCRYPTO} PARENT_SCOPE)
+    if(WOLFSSL_CAMELLIA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CAMELLIA "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_MD2 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_MD2 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_RIPEMD OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_RIPEMD "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_BLAKE2 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_BLAKE2 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_BLAKE2S OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_BLAKE2S "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SHA512 OR WOLFSSL_SHA384 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SHA512 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_DSA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_DSA "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_ECC OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_ECC "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_ED25519 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_ED25519 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_ED25519_SMALL OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_ED25519_SMALL "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_FEMATH OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_FEMATH "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_GEMATH OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_GEMATH "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CURVE25519 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CURVE25519 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CURVE25519_SMALL OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CURVE25519_SMALL "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_ED448 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_ED448 "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_ED448_SMALL ${WOLFSSL_ED448_SMALL} PARENT_SCOPE)
+    if(WOLFSSL_FE448 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_FE448 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_GE448 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_GE448 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CURVE448 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CURVE448 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CURVE448_SMALL OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CURVE448_SMALL "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_MEMORY OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_MEMORY "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_RSA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_RSA "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_DH OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_DH "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_ASN OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_ASN "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_AES OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_AES "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CODING OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CODING "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_IDEA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_IDEA "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_ARC4 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_RC4 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_MD5 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_MD5 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SHA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SHA "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_HC128 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_HC128 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_RABBIT OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_RABBIT "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_FIPS ${WOLFSSL_FIPS} PARENT_SCOPE)
+    if("${FIPS_VERSION}" STREQUAL "v1")
+        set(BUILD_FIPS_V1 "yes" PARENT_SCOPE)
+    endif()
+    if("${FIPS_VERSION}" STREQUAL "v2")
+        set(BUILD_FIPS_V2 "yes" PARENT_SCOPE)
+    endif()
+    if("${FIPS_VERSION}" STREQUAL "rand")
+        set(BUILD_FIPS_RAND "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_FIPS_READY ${FIPS_READY} PARENT_SCOPE)
+    if(WOLFSSL_CMAC OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CMAC "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_SELFTEST ${WOLFSSL_SELFTEST} PARENT_SCOPE)
+    if(WOLFSSL_SHA224 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SHA224 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SHA3 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SHA3 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_POLY1305 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_POLY1305 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CHACHA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CHACHA "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_XCHACHA OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_XCHACHA "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_INLINE ${WOLFSSL_INLINE} PARENT_SCOPE)
+    if(WOLFSSL_OCSP OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_OCSP "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_OCSP_STAPLING ${WOLFSSL_CERTIFICATE_STATUS_REQUEST} PARENT_SCOPE)
+    set(BUILD_OCSP_STAPLING_V2 ${WOLFSSL_CERTIFICATE_STATUS_REQUEST_V2} PARENT_SCOPE)
+    if(WOLFSSL_CRL OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CRL "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CRL_MONITOR)
+        set(BUILD_CRL_MONITOR "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_USER_RSA ${WOLFSSL_USER_RSA} PARENT_SCOPE)
+    set(BUILD_USER_CRYPTO ${WOLFSSL_USER_CRYPTO} PARENT_SCOPE)
+    set(BUILD_NTRU ${WOLFSSL_NTRU} PARENT_SCOPE)
+    set(BUILD_WNR ${WOLFSSL_WNR} PARENT_SCOPE)
+    if(WOLFSSL_SRP OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SRP "yes" PARENT_SCOPE)
+    endif()
+    set(USE_VALGRIND ${WOLFSSL_VALGRIND})
+    if(WOLFSSL_MD4 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_MD4 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_PWDBASED OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_PWDBASED "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SCRYPT OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SCRYPT "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_CRYPT_ONLY AND NOT WOLFSSL_OPENSSL_EXTRA)
+        set(BUILD_CRYPTONLY "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_FAST_MATH OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_FAST_MATH "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SLOW_MATH OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SLOW_MATH "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_EXAMPLES AND NOT WOLFSSL_LEAN_TLS)
+        set(BUILD_EXAMPLE_SERVERS "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_EXAMPLE_CLIENTS ${WOLFSSL_EXAMPLES} PARENT_SCOPE)
+    set(BUILD_TESTS ${WOLFSSL_EXAMPLES} PARENT_SCOPE)
+    if(NOT WOLFSSL_SINGLETHREADED AND WOLFSSL_EXAMPLES AND NOT WOLFSSL_LEAN_TLS)
+        set(BUILD_THREADED_EXAMPLES "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_WOLFCRYPT_TESTS ${WOLFSSL_CRYPT_TESTS} PARENT_SCOPE)
+    set(BUILD_LIBZ ${WOLFSSL_LIBZ} PARENT_SCOPE)
+    if(WOLFSSL_PKCS11 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_PKCS11 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_PKCS12 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_PKCS12 "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_CAVIUM ${WOLFSSL_CAVIUM} PARENT_SCOPE)
+    set(BUILD_CAVIUM_V ${WOLFSSL_CAVIUM_V} PARENT_SCOPE)
+    set(BUILD_OCTEON_SYNC ${WOLFSSL_OCTEON_SYNC} PARENT_SCOPE)
+    set(BUILD_INTEL_QA ${WOLFSSL_INTEL_QA} PARENT_SCOPE)
+    set(BUILD_INTEL_QA_SYNC ${WOLFSSL_INTEL_QA_SYNC} PARENT_SCOPE)
+    if(WOLFSSL_SP OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP "yes" PARENT_SCOPE)
+    endif()
+    if((WOLFSSL_SP AND NOT WOLFSSL_SP_ASM) OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_C "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SP_ARM64_ASM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_ARM64 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SP_ARM32_ASM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_ARM32 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SP_ARM_THUMB_ASM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_ARM_THUMB "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SP_ARM_CORTEX_ASM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_ARM_CORTEX "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SP_X86_64_ASM OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_X86_64 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_SP_MATH OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_SP_INT "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_FAST_RSA ${WOLFSSL_FAST_RSA} PARENT_SCOPE)
+    set(BUILD_MCAPI ${WOLFSSL_MCAPI} PARENT_SCOPE)
+    set(BUILD_ASYNCCRYPT ${WOLFSSL_ASYNCCRYPT} PARENT_SCOPE)
+    set(BUILD_WOLFEVENT ${WOLFSSL_ASYNCCRYPT} PARENT_SCOPE)
+    if(WOLFSSL_CRYPTOCB OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_CRYPTOCB "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_PSK ${WOLFSSL_PSK} PARENT_SCOPE)
+    set(BUILD_TRUST_PEER_CERT ${WOLFSSL_TRUSTED_PEER_CERT} PARENT_SCOPE)
+    set(BUILD_PKI ${WOLFSSL_PKI} PARENT_SCOPE)
+    if(WOLFSSL_DES3 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_DES3 "yes" PARENT_SCOPE)
+    endif()
+    if(WOLFSSL_PKCS7 OR WOLFSSL_USER_SETTINGS)
+        set(BUILD_PKCS7 "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_HASHFLAGS ${WOLFSSL_HASHFLAGS} PARENT_SCOPE)
+    set(BUILD_LINUX_KM ${WOLFSSL_LINUX_KM} PARENT_SCOPE)
+    set(BUILD_NO_LIBRARY ${WOLFSSL_NO_LIBRARY} PARENT_SCOPE)
+    if(WOLFSSL_DEBUG OR WOLFSSL_STACK_SIZE)
+        set(BUILD_DEBUG "yes" PARENT_SCOPE)
+    endif()
+    set(BUILD_RC2 ${WOLFSSL_RC2} PARENT_SCOPE)
+
+    set(BUILD_FLAGS_GENERATED "yes" PARENT_SCOPE)
+endfunction()
+
+function(generate_lib_src_list LIB_SOURCES)
+    if(NOT BUILD_FLAGS_GENERATED)
+        message(FATAL_ERROR "Cannot call generate_lib_src_list without calling generate_build_flags first.")
+    endif()
+
+    # Corresponds to src/include.am
+    if(BUILD_FIPS)
+         if(BUILD_FIPS_V1)
+              # fips first  file
+              list(APPEND LIB_SOURCES ctaocrypt/src/wolfcrypt_first.c)
+              
+              list(APPEND LIB_SOURCES
+                   ctaocrypt/src/hmac.c
+                   ctaocrypt/src/random.c 
+                   ctaocrypt/src/sha256.c)
+
+              if(BUILD_RSA)
+                   list(APPEND LIB_SOURCES ctaocrypt/src/rsa.c)
+              endif()
+
+              if(BUILD_AES)
+                   list(APPEND LIB_SOURCES ctaocrypt/src/aes.c)
+              endif()
+
+              if(BUILD_DES3)
+                   list(APPEND LIB_SOURCES ctaocrypt/src/des3.c)
+              endif()
+
+              if(BUILD_SHA)
+                   list(APPEND LIB_SOURCES ctaocrypt/src/sha.c)
+              endif()
+
+              if(BUILD_SHA512)
+                   list(APPEND LIB_SOURCES ctaocrypt/src/sha512.c)
+              endif()
+
+              list(APPEND LIB_SOURCES
+                ctaocrypt/src/fips.c
+                ctaocrypt/src/fips_test.c)
+
+              # fips last file
+              list(APPEND LIB_SOURCES ctaocrypt/src/wolfcrypt_last.c)
+         endif()
+
+         if(BUILD_FIPS_V2)
+              # FIPSv2 first file
+              list(APPEND LIB_SOURCES wolfcrypt/src/wolfcrypt_first.c)
+              
+              list(APPEND LIB_SOURCES
+                wolfcrypt/src/hmac.c 
+                wolfcrypt/src/random.c 
+                wolfcrypt/src/sha256.c)
+              
+              if(BUILD_RSA)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/rsa.c)
+              endif()
+
+              if(BUILD_ECC)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/ecc.c)
+              endif()
+
+              if(BUILD_AES)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/aes.c)
+
+                   if(BUILD_ARMASM AND BUILD_FIPS_READY)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-aes.c)
+                   endif()
+              endif()
+
+              if(BUILD_AESNI)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/aes_asm.S)
+
+                   if(BUILD_INTELASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/aes_gcm_asm.S)
+                   endif()
+              endif()
+
+              if(BUILD_DES3)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/des3.c)
+              endif()
+
+              if(BUILD_SHA)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sha.c)
+              endif()
+
+              if(BUILD_ARMASM AND BUILD_FIPS_READY)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-sha256.c)
+              endif()
+
+              if(BUILD_INTELASM)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sha256_asm.S)
+              endif()
+
+              if(BUILD_SHA512)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sha512.c)
+
+                   if(BUILD_ARMASM AND BUILD_FIPS_READY)
+                        list(APPEND LIB_SOURCES
+                             wolfcrypt/src/port/arm/armv8-sha512.c
+                             wolfcrypt/src/port/arm/armv8-sha512-asm.S
+                             wolfcrypt/src/port/arm/armv8-32-sha512-asm.S)
+                   endif()
+
+                   if(BUILD_INTELASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/sha512_asm.S)
+                   endif()
+              endif()
+
+              if(BUILD_SHA3)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sha3.c)
+              endif()
+
+              if(BUILD_DH)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/dh.c)
+              endif()
+
+              if(BUILD_CMAC)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/cmac.c)
+              endif()
+
+              list(APPEND LIB_SOURCES
+                   wolfcrypt/src/fips.c
+                   wolfcrypt/src/fips_test.c)
+
+              # fips last file
+              list(APPEND LIB_SOURCES wolfcrypt/src/wolfcrypt_last.c)
+         endif()
+
+         if(BUILD_FIPS_RAND)
+              list(APPEND LIB_SOURCES
+                   wolfcrypt/src/wolfcrypt_first.c 
+                   wolfcrypt/src/hmac.c 
+                   wolfcrypt/src/random.c 
+                   wolfcrypt/src/sha256.c 
+                   wolfcrypt/src/sha256_asm.S 
+                   wolfcrypt/src/fips.c 
+                   wolfcrypt/src/fips_test.c 
+                   wolfcrypt/src/wolfcrypt_last.c)
+         endif()
+    endif() 
+
+    # For wolfRand, exclude everything else.
+    if(NOT BUILD_FIPS_RAND)
+         # For FIPSV2, exclude the wolfCrypt files included above.
+         # For wolfRand, exclude just a couple files.
+         # For old FIPS, keep the wolfCrypt versions of the
+         # CtaoCrypt files included above.
+         if(NOT BUILD_FIPS_V2)
+              list(APPEND LIB_SOURCES wolfcrypt/src/hmac.c)
+         endif()
+
+         # CAVP self test
+         if(BUILD_SELFTEST)
+              list(APPEND LIB_SOURCES wolfcrypt/src/selftest.c)
+         endif()
+    endif()
+
+    list(APPEND LIB_SOURCES
+         wolfcrypt/src/hash.c 
+         wolfcrypt/src/cpuid.c)
+
+    if(NOT BUILD_FIPS_RAND)
+         if(NOT BUILD_FIPS_V2 AND BUILD_RNG)
+              list(APPEND LIB_SOURCES wolfcrypt/src/random.c)
+         endif()
+
+         if(NOT BUILD_FIPS_V2)
+              if(BUILD_ARMASM)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-sha256.c)
+              else()
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sha256.c)
+
+                   if(BUILD_INTELASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/sha256_asm.S)
+                   endif()
+              endif()
+         endif()
+
+         if(BUILD_AFALG)
+              list(APPEND LIB_SOURCES wolfcrypt/src/port/af_alg/afalg_hash.c)
+         endif()
+
+         if(BUILD_WOLFEVENT)
+              list(APPEND LIB_SOURCES wolfcrypt/src/wolfevent.c)
+         endif()
+
+         if(BUILD_ASYNCCRYPT)
+              list(APPEND LIB_SOURCES wolfcrypt/src/async.c)
+         endif()
+
+         if(NOT BUILD_USER_RSA AND BUILD_RSA)
+              if(BUILD_FAST_RSA)
+                   list(APPEND LIB_SOURCES wolfcrypt/user-crypto/src/rsa.c)
+              else()
+                   if(NOT BUILD_FIPS_V2)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/rsa.c)
+                   endif()
+              endif()
+         endif()
+
+         if(BUILD_SP)
+              if(BUILD_SP_C)
+                   list(APPEND LIB_SOURCES
+                        wolfcrypt/src/sp_c32.c
+                        wolfcrypt/src/sp_c64.c)
+              endif()
+
+              if(BUILD_SP_X86_64)
+                   list(APPEND LIB_SOURCES 
+                        wolfcrypt/src/sp_x86_64.c
+                        wolfcrypt/src/sp_x86_64_asm.S)
+              endif()
+
+              if(NOT BUILD_FIPS_V2 AND BUILD_SP_ARM32)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sp_arm32.c)
+              endif()
+
+              if(BUILD_SP_ARM_THUMB)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sp_armthumb.c)
+              endif()
+              
+              if(BUILD_SP_ARM64)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sp_arm64.c)
+              endif()
+
+              if(BUILD_SP_INT)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sp_int.c)
+              endif()
+              
+              if(BUILD_SP_ARM_CORTEX)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sp_cortexm.c)
+              endif()
+         endif()
+
+         if(NOT BUILD_FIPS_V2)
+              if(BUILD_AES)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/aes.c)
+
+                   if(BUILD_ARMASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-aes.c)
+                   endif()
+
+                   if(BUILD_AFALG)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/port/af_alg/afalg_aes.c)
+                   endif()
+              endif()
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_CMAC)
+              list(APPEND LIB_SOURCES wolfcrypt/src/cmac.c)
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_DES3)
+              list(APPEND LIB_SOURCES wolfcrypt/src/des3.c)
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_SHA)
+              list(APPEND LIB_SOURCES wolfcrypt/src/sha.c)
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_SHA512)
+              if(BUILD_ARMASM)
+                   list(APPEND LIB_SOURCES
+                        wolfcrypt/src/port/arm/armv8-sha512.c
+                        wolfcrypt/src/port/arm/armv8-sha512-asm.S
+                        wolfcrypt/src/port/arm/armv8-32-sha512-asm.S)
+              else()
+                   list(APPEND LIB_SOURCES wolfcrypt/src/sha512.c)
+
+                   if(BUILD_INTELASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/sha512_asm.S)
+                   endif()
+              endif()
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_SHA3)
+              list(APPEND LIB_SOURCES wolfcrypt/src/sha3.c)
+         endif()
+    endif()
+
+    list(APPEND LIB_SOURCES
+         wolfcrypt/src/logging.c 
+         wolfcrypt/src/wc_port.c 
+         wolfcrypt/src/error.c)
+
+    if(BUILD_DEBUG)
+         list(APPEND LIB_SOURCES
+              wolfcrypt/src/debug.c)
+    endif()
+
+    if(NOT BUILD_FIPS_RAND)
+         list(APPEND LIB_SOURCES
+              wolfcrypt/src/wc_encrypt.c 
+              wolfcrypt/src/signature.c 
+              wolfcrypt/src/wolfmath.c)
+    endif()
+
+    if(BUILD_MEMORY)
+         list(APPEND LIB_SOURCES wolfcrypt/src/memory.c)
+    endif()
+
+    if(NOT BUILD_FIPS_RAND)
+         if(NOT BUILD_FIPS_V2 AND BUILD_DH)
+              list(APPEND LIB_SOURCES wolfcrypt/src/dh.c)
+         endif()
+
+         if(BUILD_ASN)
+              list(APPEND LIB_SOURCES wolfcrypt/src/asn.c)
+         endif()
+    endif()
+
+    if(BUILD_CODING)
+         list(APPEND LIB_SOURCES wolfcrypt/src/coding.c)
+    endif()
+
+    if(NOT BUILD_FIPS_RAND)
+         if(BUILD_POLY1305)
+              if(BUILD_ARMASM)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-poly1305.c)
+              endif()
+
+              list(APPEND LIB_SOURCES wolfcrypt/src/poly1305.c)
+
+              if(BUILD_INTELASM)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/poly1305_asm.S)
+              endif()
+         endif()
+
+         if(BUILD_RC4)
+              list(APPEND LIB_SOURCES wolfcrypt/src/arc4.c)
+         endif()
+
+         if(BUILD_MD4)
+              list(APPEND LIB_SOURCES wolfcrypt/src/md4.c)
+         endif()
+
+         if(BUILD_MD5)
+              list(APPEND LIB_SOURCES wolfcrypt/src/md5.c)
+         endif()
+
+         if(BUILD_PWDBASED)
+              list(APPEND LIB_SOURCES
+                   wolfcrypt/src/pwdbased.c
+                   wolfcrypt/src/pkcs12.c)
+         endif()
+
+         if(BUILD_DSA)
+              list(APPEND LIB_SOURCES wolfcrypt/src/dsa.c)
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_AESNI)
+              list(APPEND LIB_SOURCES
+                   wolfcrypt/src/aes_asm.S
+                   wolfcrypt/src/aes_gcm_asm.S)
+         endif()
+         
+         if(BUILD_CAMELLIA)
+              list(APPEND LIB_SOURCES wolfcrypt/src/camellia.c)
+         endif()
+
+         if(BUILD_MD2)
+              list(APPEND LIB_SOURCES wolfcrypt/src/md2.c)
+         endif()
+
+         if(BUILD_RIPEMD)
+              list(APPEND LIB_SOURCES wolfcrypt/src/ripemd.c)
+         endif()
+
+         if(BUILD_BLAKE2)
+              list(APPEND LIB_SOURCES wolfcrypt/src/blake2b.c)
+         endif()
+         
+         if(BUILD_BLAKE2S)
+              list(APPEND LIB_SOURCES wolfcrypt/src/blake2s.c)
+         endif()
+
+         if(BUILD_HC128)
+              list(APPEND LIB_SOURCES wolfcrypt/src/hc128.c)
+         endif()
+
+         if(BUILD_RABBIT)
+              list(APPEND LIB_SOURCES wolfcrypt/src/rabbit.c)
+         endif()
+
+         if(BUILD_CHACHA)
+              if(BUILD_ARMASM)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-chacha.c)
+              else()
+                   list(APPEND LIB_SOURCES wolfcrypt/src/chacha.c)
+
+                   if(BUILD_INTELASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/chacha_asm.S)
+                   endif()
+              endif()
+
+              if(BUILD_POLY1305)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/chacha20_poly1305.c)
+              endif()
+         endif()
+
+         if(NOT BUILD_INLINE)
+              list(APPEND LIB_SOURCES wolfcrypt/src/misc.c)
+         endif()
+
+         if(BUILD_FAST_MATH)
+              list(APPEND LIB_SOURCES wolfcrypt/src/tfm.c)
+         endif()
+
+         if(BUILD_SLOW_MATH)
+              list(APPEND LIB_SOURCES wolfcrypt/src/integer.c)
+         endif()
+
+         if(NOT BUILD_FIPS_V2 AND BUILD_ECC)
+              list(APPEND LIB_SOURCES wolfcrypt/src/ecc.c)
+         endif()
+
+         if(BUILD_CURVE25519)
+              list(APPEND LIB_SOURCES wolfcrypt/src/curve25519.c)
+         endif()
+
+         if(BUILD_ED25519)
+              list(APPEND LIB_SOURCES wolfcrypt/src/ed25519.c)
+         endif()
+
+         if(BUILD_FEMATH)
+              if(BUILD_CURVE25519_SMALL)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/fe_low_mem.c)
+              else()
+                   if(BUILD_INTELASM)
+                        list(APPEND LIB_SOURCES wolfcrypt/src/fe_x25519_asm.S)
+                   else()
+                        if(BUILD_ARMASM)
+                             list(APPEND LIB_SOURCES
+                                  wolfcrypt/src/port/arm/armv8-32-curve25519.S
+                                  wolfcrypt/src/port/arm/armv8-curve25519.S)
+                        else()
+                             list(APPEND LIB_SOURCES wolfcrypt/src/fe_operations.c)
+                        endif()
+                   endif()
+              endif()
+         endif()
+
+         if(BUILD_GEMATH)
+              if(BUILD_ED25519_SMALL)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/ge_low_mem.c)
+              else()
+                   list(APPEND LIB_SOURCES wolfcrypt/src/ge_operations.c)
+
+                   if(NOT BUILD_FEMATH)
+                        if(BUILD_INTELASM)
+                             list(APPEND LIB_SOURCES wolfcrypt/src/fe_x25519_asm.S)
+                        else()
+                             if(BUILD_ARMASM)
+                                  list(APPEND LIB_SOURCES wolfcrypt/src/port/arm/armv8-curve25519.S)
+                             else()
+                                  list(APPEND LIB_SOURCES wolfcrypt/src/fe_operations.c)
+                             endif()
+                        endif()
+                   endif()
+              endif()
+         endif()
+
+         if(BUILD_CURVE448)
+              list(APPEND LIB_SOURCES wolfcrypt/src/curve448.c)
+         endif()
+
+         if(BUILD_ED448)
+              list(APPEND LIB_SOURCES wolfcrypt/src/ed448.c)
+         endif()
+
+         if(BUILD_FE448)
+              list(APPEND LIB_SOURCES wolfcrypt/src/fe_448.c)
+         endif()
+
+         if(BUILD_GE448)
+              list(APPEND LIB_SOURCES wolfcrypt/src/ge_448.c)
+
+              if(NOT BUILD_FE448)
+                   list(APPEND LIB_SOURCES wolfcrypt/src/fe_448.c)
+              endif()
+         endif()
+
+         if(BUILD_LIBZ)
+              list(APPEND LIB_SOURCES wolfcrypt/src/compress.c)
+         endif()
+
+         if(BUILD_PKCS7)
+              list(APPEND LIB_SOURCES wolfcrypt/src/pkcs7.c)
+         endif()
+
+         if(BUILD_SRP)
+              list(APPEND LIB_SOURCES wolfcrypt/src/srp.c)
+         endif()
+
+         if(BUILD_IDEA)
+              list(APPEND LIB_SOURCES wolfcrypt/src/idea.c)
+         endif()
+
+         if(BUILD_AFALG)
+              list(APPEND LIB_SOURCES wolfcrypt/src/port/af_alg/wc_afalg.c)
+         endif()
+
+         if(NOT BUILD_CRYPTONLY)
+              # ssl files
+              list(APPEND LIB_SOURCES
+                   src/internal.c 
+                   src/wolfio.c 
+                   src/keys.c 
+                   src/ssl.c 
+                   src/tls.c)
+
+              if(BUILD_TLS13)
+                   list(APPEND LIB_SOURCES src/tls13.c)
+              endif()
+
+              if(BUILD_OCSP)
+                   list(APPEND LIB_SOURCES src/ocsp.c)
+              endif()
+
+              if(BUILD_CRL)
+                   list(APPEND LIB_SOURCES src/crl.c)
+              endif()
+
+              if(BUILD_SNIFFER)
+                   list(APPEND LIB_SOURCES src/sniffer.c)
+              endif()
+         endif()
+    endif()
+
+    # Corresponds to wolfcrypt/src/include.am
+    if(BUILD_CRYPTOCB)
+           list(APPEND LIB_SOURCES wolfcrypt/src/cryptocb.c)
+    endif()
+
+    if(BUILD_PKCS11)
+           list(APPEND LIB_SOURCES wolfcrypt/src/wc_pkcs11.c)
+    endif()
+
+    if(BUILD_DEVCRYPTO)
+        list(APPEND LIB_SOURCES
+            wolfcrypt/src/port/devcrypto/devcrypto_hash.c
+            wolfcrypt/src/port/devcrypto/devcrypto_aes.c
+            wolfcrypt/src/port/devcrypto/wc_devcrypto.c)
+    endif()
+
+    if(BUILD_CAVIUM)
+        list(APPEND LIB_SOURCES wolfcrypt/src/port/cavium/cavium_nitrox.c)
+    endif()
+
+    if(BUILD_OCTEON_SYNC)
+        list(APPEND LIB_SOURCES wolfcrypt/src/port/cavium/cavium_octeon_sync.c)
+    endif()
+
+    if(BUILD_INTEL_QA)
+        list(APPEND LIB_SOURCES
+            wolfcrypt/src/port/intel/quickassist.c
+            wolfcrypt/src/port/intel/quickassist_mem.c)
+    endif()
+
+    if(BUILD_INTEL_QA_SYNC)
+        list(APPEND LIB_SOURCES wolfcrypt/src/port/intel/quickassist_sync.c)
+    endif()
+
+    if(BUILD_CRYPTOAUTHLIB)
+        list(APPEND LIB_SOURCES wolfcrypt/src/port/atmel/atmel.c)
+    endif()
+
+    set(LIB_SOURCES ${LIB_SOURCES} PARENT_SCOPE)
+endfunction()

+ 2 - 0
cmake/include.am

@@ -0,0 +1,2 @@
+EXTRA_DIST += cmake/config.in
+EXTRA_DIST += cmake/functions.cmake

Some files were not shown because too many files changed in this diff