# sub-directory 'libbson' was already included at the top-level
# sub-directory 'libmongoc' was already included at the top-level
# sub-directory 'kms-message' was already included at the top-level
add_subdirectory (tools)
add_subdirectory (common)

# zconf.h is generated by configure_file() in the parent CMakeLists.txt
extra_dist_generated (zlib-1.2.11/zconf.h)
set (src_zlib_DIST
   src/zlib-1.2.11/crc32.h
   src/zlib-1.2.11/deflate.h
   src/zlib-1.2.11/gzguts.h
   src/zlib-1.2.11/inffast.h
   src/zlib-1.2.11/inffixed.h
   src/zlib-1.2.11/inflate.h
   src/zlib-1.2.11/inftrees.h
   src/zlib-1.2.11/trees.h
   src/zlib-1.2.11/zconf.h.in
   src/zlib-1.2.11/zlib.h
   src/zlib-1.2.11/zutil.h
)
# Strip leading directory components to make the paths relative for MakeDist.
# The ZLIB_SOURCES list is set in the top-level CMakeLists.txt.
foreach (zlib_src IN LISTS ZLIB_SOURCES)
   string (REPLACE "${SOURCE_DIR}/" "" zlib_src_rel ${zlib_src})
   list (APPEND src_zlib_DIST ${zlib_src_rel})
endforeach ()

file (GLOB_RECURSE src_kms_message_DIST RELATIVE "${SOURCE_DIR}" kms-message/*)

set_local_dist (src_DIST_local
   CMakeLists.txt
)

set (src_DIST
   ${src_DIST_local}
   ${src_tools_DIST}
   ${src_zlib_DIST}
   ${src_common_DIST}
   ${src_kms_message_DIST}
   PARENT_SCOPE
)
