summaryrefslogtreecommitdiff
path: root/absl
diff options
context:
space:
mode:
authorGravatar Gennadiy Civil <gennadiycivil@users.noreply.github.com>2017-11-06 12:56:37 -0800
committerGravatar GitHub <noreply@github.com>2017-11-06 12:56:37 -0800
commit78e1abca86f4294ab26ef36e534798b893c828bd (patch)
treeb4cd4da6696aed4d103a087c56bf363c4abe707c /absl
parentda336a84e9c1f86409b21996164ae9602b37f9ca (diff)
parent2eedcf020483cdbfd49a796fb78a3edd0134b8e6 (diff)
Merge pull request #8 from adevress/master
Add CMake support
Diffstat (limited to 'absl')
-rw-r--r--absl/CMakeLists.txt30
-rw-r--r--absl/algorithm/CMakeLists.txt63
-rw-r--r--absl/base/CMakeLists.txt341
-rw-r--r--absl/container/CMakeLists.txt126
-rw-r--r--absl/debugging/CMakeLists.txt93
-rw-r--r--absl/memory/CMakeLists.txt52
-rw-r--r--absl/meta/CMakeLists.txt49
-rw-r--r--absl/numeric/CMakeLists.txt62
-rw-r--r--absl/strings/CMakeLists.txt299
-rw-r--r--absl/synchronization/CMakeLists.txt154
-rw-r--r--absl/time/CMakeLists.txt78
-rw-r--r--absl/types/CMakeLists.txt171
-rw-r--r--absl/utility/CMakeLists.txt60
13 files changed, 1578 insertions, 0 deletions
diff --git a/absl/CMakeLists.txt b/absl/CMakeLists.txt
new file mode 100644
index 00000000..689f64e2
--- /dev/null
+++ b/absl/CMakeLists.txt
@@ -0,0 +1,30 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+
+
+add_subdirectory(base)
+add_subdirectory(algorithm)
+add_subdirectory(container)
+add_subdirectory(debugging)
+add_subdirectory(memory)
+add_subdirectory(meta)
+add_subdirectory(numeric)
+add_subdirectory(strings)
+add_subdirectory(synchronization)
+add_subdirectory(time)
+add_subdirectory(types)
+add_subdirectory(utility)
diff --git a/absl/algorithm/CMakeLists.txt b/absl/algorithm/CMakeLists.txt
new file mode 100644
index 00000000..fdf45c55
--- /dev/null
+++ b/absl/algorithm/CMakeLists.txt
@@ -0,0 +1,63 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND ALGORITHM_PUBLIC_HEADERS
+ "algorithm.h"
+ "container.h"
+)
+
+
+#
+## TESTS
+#
+
+# test algorithm_test
+list(APPEND ALGORITHM_TEST_SRC
+ "algorithm_test.cc"
+ ${ALGORITHM_PUBLIC_HEADERS}
+ ${ALGORITHM_INTERNAL_HEADERS}
+)
+
+absl_header_library(
+ TARGET
+ absl_algorithm
+ EXPORT_NAME
+ algorithm
+)
+
+absl_test(
+ TARGET
+ algorithm_test
+ SOURCES
+ ${ALGORITHM_TEST_SRC}
+ PUBLIC_LIBRARIES
+ absl::algorithm
+)
+
+
+
+
+# test container_test
+set(CONTAINER_TEST_SRC "container_test.cc")
+
+absl_test(
+ TARGET
+ container_test
+ SOURCES
+ ${CONTAINER_TEST_SRC}
+ PUBLIC_LIBRARIES
+ absl::algorithm
+)
diff --git a/absl/base/CMakeLists.txt b/absl/base/CMakeLists.txt
new file mode 100644
index 00000000..3e94d51f
--- /dev/null
+++ b/absl/base/CMakeLists.txt
@@ -0,0 +1,341 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND BASE_PUBLIC_HEADERS
+ "attributes.h"
+ "call_once.h"
+ "casts.h"
+ "config.h"
+ "dynamic_annotations.h"
+ "macros.h"
+ "optimization.h"
+ "policy_checks.h"
+ "port.h"
+ "thread_annotations.h"
+)
+
+
+list(APPEND BASE_INTERNAL_HEADERS
+ "internal/atomic_hook.h"
+ "internal/cycleclock.h"
+ "internal/endian.h"
+ "internal/exception_testing.h"
+ "internal/identity.h"
+ "internal/invoke.h"
+ "internal/log_severity.h"
+ "internal/low_level_alloc.h"
+ "internal/low_level_scheduling.h"
+ "internal/malloc_extension_c.h"
+ "internal/malloc_extension.h"
+ "internal/malloc_hook_c.h"
+ "internal/malloc_hook.h"
+ "internal/malloc_hook_invoke.h"
+ "internal/per_thread_tls.h"
+ "internal/raw_logging.h"
+ "internal/scheduling_mode.h"
+ "internal/spinlock.h"
+ "internal/spinlock_wait.h"
+ "internal/sysinfo.h"
+ "internal/thread_identity.h"
+ "internal/throw_delegate.h"
+ "internal/tsan_mutex_interface.h"
+ "internal/unaligned_access.h"
+ "internal/unscaledcycleclock.h"
+)
+
+
+# absl_base main library
+list(APPEND BASE_SRC
+ "internal/cycleclock.cc"
+ "internal/raw_logging.cc"
+ "internal/spinlock.cc"
+ "internal/sysinfo.cc"
+ "internal/thread_identity.cc"
+ "internal/unscaledcycleclock.cc"
+ "internal/low_level_alloc.cc"
+ "internal/malloc_hook.cc"
+ ${BASE_PUBLIC_HEADERS}
+ ${BASE_INTERNAL_HEADERS}
+)
+
+absl_library(
+ TARGET
+ absl_base
+ SOURCES
+ ${BASE_SRC}
+ PUBLIC_LIBRARIES
+ absl_dynamic_annotations
+ absl_spinlock_wait
+ EXPORT_NAME
+ base
+)
+
+# malloc extension library
+set(MALLOC_EXTENSION_SRC "internal/malloc_extension.cc")
+set(MALLOC_EXTENSION_PUBLIC_LIBRARIES absl::base)
+
+absl_library(
+ TARGET
+ absl_malloc_extension
+ SOURCES
+ ${MALLOC_EXTENSION_SRC}
+ PUBLIC_LIBRARIES
+ ${MALLOC_EXTENSION_PUBLIC_LIBRARIES}
+ EXPORT_NAME
+ malloc_extension
+)
+
+# throw delegate library
+set(THROW_DELEGATE_SRC "internal/throw_delegate.cc")
+
+absl_library(
+ TARGET
+ absl_throw_delegate
+ SOURCES
+ ${THROW_DELEGATE_SRC}
+ PUBLIC_LIBRARIES
+ ${THROW_DELEGATE_PUBLIC_LIBRARIES}
+ PRIVATE_COMPILE_FLAGS
+ ${ABSL_EXCEPTIONS_FLAG}
+ EXPORT_NAME
+ throw_delegate
+)
+
+
+# dynamic_annotations library
+set(DYNAMIC_ANNOTATIONS_SRC "dynamic_annotations.cc")
+
+absl_library(
+ TARGET
+ absl_dynamic_annotations
+ SOURCES
+ ${DYNAMIC_ANNOTATIONS_SRC}
+)
+
+
+# spinlock_wait library
+set(SPINLOCK_WAIT_SRC "internal/spinlock_wait.cc")
+
+absl_library(
+ TARGET
+ absl_spinlock_wait
+ SOURCES
+ ${SPINLOCK_WAIT_SRC}
+)
+
+
+# malloc_internal library
+list(APPEND MALLOC_INTERNAL_SRC
+ "internal/low_level_alloc.cc"
+ "internal/malloc_hook.cc"
+ "internal/malloc_hook_mmap_linux.inc"
+)
+
+absl_library(
+ TARGET
+ absl_malloc_internal
+ SOURCES
+ ${MALLOC_INTERNAL_SRC}
+ PUBLIC_LIBRARIES
+ absl_dynamic_annotations
+)
+
+
+
+#
+## TESTS
+#
+
+# call once test
+set(CALL_ONCE_TEST_SRC "call_once_test.cc")
+set(CALL_ONCE_TEST_PUBLIC_LIBRARIES absl::base absl::synchronization)
+
+absl_test(
+ TARGET
+ call_once_test
+ SOURCES
+ ${CALL_ONCE_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${CALL_ONCE_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test bit_cast_test
+set(BIT_CAST_TEST_SRC "bit_cast_test.cc")
+
+absl_test(
+ TARGET
+ bit_cast_test
+ SOURCES
+ ${BIT_CAST_TEST_SRC}
+)
+
+
+# test absl_throw_delegate_test
+set(THROW_DELEGATE_TEST_SRC "throw_delegate_test.cc")
+set(THROW_DELEGATE_TEST_PUBLIC_LIBRARIES absl::base absl_throw_delegate)
+
+absl_test(
+ TARGET
+ throw_delegate_test
+ SOURCES
+ ${THROW_DELEGATE_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${THROW_DELEGATE_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test invoke_test
+set(INVOKE_TEST_SRC "invoke_test.cc")
+set(INVOKE_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ invoke_test
+ SOURCES
+ ${INVOKE_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${INVOKE_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test spinlock_test_common
+set(SPINLOCK_TEST_COMMON_SRC "spinlock_test_common.cc")
+set(SPINLOCK_TEST_COMMON_PUBLIC_LIBRARIES absl::base absl::synchronization)
+
+absl_test(
+ TARGET
+ spinlock_test_common
+ SOURCES
+ ${SPINLOCK_TEST_COMMON_SRC}
+ PUBLIC_LIBRARIES
+ ${SPINLOCK_TEST_COMMON_PUBLIC_LIBRARIES}
+)
+
+
+# test spinlock_test
+set(SPINLOCK_TEST_SRC "spinlock_test_common.cc")
+set(SPINLOCK_TEST_PUBLIC_LIBRARIES absl::base absl::synchronization)
+
+absl_test(
+ TARGET
+ spinlock_test
+ SOURCES
+ ${SPINLOCK_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${SPINLOCK_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test endian_test
+set(ENDIAN_TEST_SRC "internal/endian_test.cc")
+
+absl_test(
+ TARGET
+ endian_test
+ SOURCES
+ ${ENDIAN_TEST_SRC}
+)
+
+
+# test config_test
+set(CONFIG_TEST_SRC "config_test.cc")
+set(CONFIG_TEST_PUBLIC_LIBRARIES absl::base absl::synchronization)
+absl_test(
+ TARGET
+ config_test
+ SOURCES
+ ${CONFIG_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${CONFIG_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test raw_logging_test
+set(RAW_LOGGING_TEST_SRC "raw_logging_test.cc")
+set(RAW_LOGGING_TEST_PUBLIC_LIBRARIES absl::base)
+
+absl_test(
+ TARGET
+ raw_logging_test
+ SOURCES
+ ${RAW_LOGGING_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${RAW_LOGGING_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test sysinfo_test
+set(SYSINFO_TEST_SRC "internal/sysinfo_test.cc")
+set(SYSINFO_TEST_PUBLIC_LIBRARIES absl::base absl::synchronization)
+
+absl_test(
+ TARGET
+ sysinfo_test
+ SOURCES
+ ${SYSINFO_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${SYSINFO_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test low_level_alloc_test
+set(LOW_LEVEL_ALLOC_TEST_SRC "internal/low_level_alloc_test.cc")
+set(LOW_LEVEL_ALLOC_TEST_PUBLIC_LIBRARIES absl::base)
+
+absl_test(
+ TARGET
+ low_level_alloc_test
+ SOURCES
+ ${LOW_LEVEL_ALLOC_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${LOW_LEVEL_ALLOC_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test thread_identity_test
+set(THREAD_IDENTITY_TEST_SRC "internal/thread_identity_test.cc")
+set(THREAD_IDENTITY_TEST_PUBLIC_LIBRARIES absl::base absl::synchronization)
+
+absl_test(
+ TARGET
+ thread_identity_test
+ SOURCES
+ ${THREAD_IDENTITY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${THREAD_IDENTITY_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test absl_malloc_extension_system_malloc_test
+set(MALLOC_EXTENSION_SYSTEM_MALLOC_TEST_SRC "internal/malloc_extension_test.cc")
+set(MALLOC_EXTENSION_SYSTEM_MALLOC_TEST_PUBLIC_LIBRARIES absl::base absl_malloc_extension)
+set(MALLOC_EXTENSION_SYSTEM_MALLOC_TEST_PRIVATE_COMPILE_FLAGS "-DABSL_MALLOC_EXTENSION_TEST_ALLOW_MISSING_EXTENSION=1")
+
+absl_test(
+ TARGET
+ absl_malloc_extension_system_malloc_test
+ SOURCES
+ ${MALLOC_EXTENSION_SYSTEM_MALLOC_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${MALLOC_EXTENSION_SYSTEM_MALLOC_TEST_PUBLIC_LIBRARIES}
+ PRIVATE_COMPILE_FLAGS
+ ${MALLOC_EXTENSION_SYSTEM_MALLOC_TEST_PRIVATE_COMPILE_FLAGS}
+)
+
+
+
+
diff --git a/absl/container/CMakeLists.txt b/absl/container/CMakeLists.txt
new file mode 100644
index 00000000..f56ce92d
--- /dev/null
+++ b/absl/container/CMakeLists.txt
@@ -0,0 +1,126 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+
+list(APPEND CONTAINER_PUBLIC_HEADERS
+ "fixed_array.h"
+ "inlined_vector.h"
+)
+
+
+list(APPEND CONTAINER_INTERNAL_HEADERS
+ "internal/test_instance_tracker.h"
+)
+
+
+absl_header_library(
+ TARGET
+ absl_container
+ EXPORT_NAME
+ container
+)
+
+
+#
+## TESTS
+#
+
+list(APPEND TEST_INSTANCE_TRACKER_LIB_SRC
+ "internal/test_instance_tracker.cc"
+ ${CONTAINER_PUBLIC_HEADERS}
+ ${CONTAINER_INTERNAL_HEADERS}
+)
+
+
+absl_library(
+ TARGET
+ test_instance_tracker_lib
+ SOURCES
+ ${TEST_INSTANCE_TRACKER_LIB_SRC}
+ PUBLIC_LIBRARIES
+ absl::container
+ DISABLE_INSTALL
+)
+
+
+
+# test fixed_array_test
+set(FIXED_ARRAY_TEST_SRC "fixed_array_test.cc")
+set(FIXED_ARRAY_TEST_PUBLIC_LIBRARIES absl::base absl_throw_delegate test_instance_tracker_lib)
+
+absl_test(
+ TARGET
+ fixed_array_test
+ SOURCES
+ ${FIXED_ARRAY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${FIXED_ARRAY_TEST_PUBLIC_LIBRARIES}
+ PRIVATE_COMPILE_FLAGS
+ ${ABSL_EXCEPTIONS_FLAG}
+)
+
+
+
+absl_test(
+ TARGET
+ fixed_array_test_noexceptions
+ SOURCES
+ ${FIXED_ARRAY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${FIXED_ARRAY_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test inlined_vector_test
+set(INLINED_VECTOR_TEST_SRC "inlined_vector_test.cc")
+set(INLINED_VECTOR_TEST_PUBLIC_LIBRARIES absl::base absl_throw_delegate test_instance_tracker_lib)
+
+absl_test(
+ TARGET
+ inlined_vector_test
+ SOURCES
+ ${INLINED_VECTOR_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${INLINED_VECTOR_TEST_PUBLIC_LIBRARIES}
+)
+
+absl_test(
+ TARGET
+ inlined_vector_test_noexceptions
+ SOURCES
+ ${INLINED_VECTOR_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${INLINED_VECTOR_TEST_PUBLIC_LIBRARIES}
+ PRIVATE_COMPILE_FLAGS
+ ${ABSL_NOEXCEPTION_CXXFLAGS}
+)
+
+
+# test test_instance_tracker_test
+set(TEST_INSTANCE_TRACKER_TEST_SRC "internal/test_instance_tracker_test.cc")
+set(TEST_INSTANCE_TRACKER_TEST_PUBLIC_LIBRARIES absl::base absl_throw_delegate test_instance_tracker_lib)
+
+
+absl_test(
+ TARGET
+ test_instance_tracker_test
+ SOURCES
+ ${TEST_INSTANCE_TRACKER_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${TEST_INSTANCE_TRACKER_TEST_PUBLIC_LIBRARIES}
+)
+
+
diff --git a/absl/debugging/CMakeLists.txt b/absl/debugging/CMakeLists.txt
new file mode 100644
index 00000000..57efe80f
--- /dev/null
+++ b/absl/debugging/CMakeLists.txt
@@ -0,0 +1,93 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND DEBUGGING_PUBLIC_HEADERS
+ "leak_check.h"
+ "stacktrace.h"
+)
+
+
+list(APPEND DEBUGGING_INTERNAL_HEADERS
+ "internal/address_is_readable.h"
+ "internal/elf_mem_image.h"
+ "internal/stacktrace_config.h"
+ "internal/vdso_support.h"
+)
+
+
+list(APPEND STACKTRACE_SRC
+ "stacktrace.cc"
+ "internal/address_is_readable.cc"
+ "internal/elf_mem_image.cc"
+ "internal/vdso_support.cc"
+ ${DEBUGGING_PUBLIC_HEADERS}
+ ${DEBUGGING_INTERNAL_HEADERS}
+)
+
+absl_library(
+ TARGET
+ absl_stacktrace
+ SOURCES
+ ${STACKTRACE_SRC}
+ EXPORT_NAME
+ stacktrace
+)
+
+
+list(APPEND LEAK_CHECK_SRC
+ "leak_check.cc"
+)
+
+
+# leak_check library
+absl_library(
+ TARGET
+ absl_leak_check
+ SOURCES
+ ${LEAK_CHECK_SRC}
+ PUBLIC_LIBRARIES
+ absl_base
+ EXPORT_NAME
+ leak_check
+)
+
+
+# component target
+absl_header_library(
+ TARGET
+ absl_debugging
+ PUBLIC_LIBRARIES
+ absl_stacktrace absl_leak_check
+ EXPORT_NAME
+ debugging
+)
+
+#
+## TESTS
+#
+
+# test leak_check_test
+list(APPEND LEAK_CHECK_TEST_SRC "leak_check_test.cc")
+
+absl_test(
+ TARGET
+ leak_check_test
+ SOURCES
+ ${LEAK_CHECK_TEST_SRC}
+ PUBLIC_LIBRARIES
+ absl_leak_check
+)
+
diff --git a/absl/memory/CMakeLists.txt b/absl/memory/CMakeLists.txt
new file mode 100644
index 00000000..21bfc87e
--- /dev/null
+++ b/absl/memory/CMakeLists.txt
@@ -0,0 +1,52 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND MEMORY_PUBLIC_HEADERS
+ "memory.h"
+)
+
+
+absl_header_library(
+ TARGET
+ absl_memory
+ EXPORT_NAME
+ memory
+)
+
+#
+## TESTS
+#
+
+# test memory_test
+list(APPEND MEMORY_TEST_SRC
+ "memory_test.cc"
+ ${MEMORY_PUBLIC_HEADERS}
+)
+set(MEMORY_TEST_PUBLIC_LIBRARIES absl::base absl::memory)
+
+
+
+absl_test(
+ TARGET
+ memory_test
+ SOURCES
+ ${MEMORY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${MEMORY_TEST_PUBLIC_LIBRARIES}
+)
+
+
+
diff --git a/absl/meta/CMakeLists.txt b/absl/meta/CMakeLists.txt
new file mode 100644
index 00000000..d56fced8
--- /dev/null
+++ b/absl/meta/CMakeLists.txt
@@ -0,0 +1,49 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND META_PUBLIC_HEADERS
+ "type_traits.h"
+)
+
+
+#
+## TESTS
+#
+
+# test type_traits_test
+list(APPEND TYPE_TRAITS_TEST_SRC
+ "type_traits_test.cc"
+ ${META_PUBLIC_HEADERS}
+)
+
+absl_header_library(
+ TARGET
+ absl_meta
+ EXPORT_NAME
+ meta
+ )
+
+absl_test(
+ TARGET
+ type_traits_test
+ SOURCES
+ ${TYPE_TRAITS_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${TYPE_TRAITS_TEST_PUBLIC_LIBRARIES} absl::meta
+)
+
+
+
diff --git a/absl/numeric/CMakeLists.txt b/absl/numeric/CMakeLists.txt
new file mode 100644
index 00000000..3360b2ee
--- /dev/null
+++ b/absl/numeric/CMakeLists.txt
@@ -0,0 +1,62 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND NUMERIC_PUBLIC_HEADERS
+ "int128.h"
+)
+
+
+# library 128
+list(APPEND INT128_SRC
+ "int128.cc"
+ ${NUMERIC_PUBLIC_HEADERS}
+)
+absl_library(
+ TARGET
+ absl_int128
+ SOURCES
+ ${INT128_SRC}
+ PUBLIC_LIBRARIES
+ ${INT128_PUBLIC_LIBRARIES}
+ EXPORT_NAME
+ int128
+)
+
+
+absl_header_library(
+ TARGET
+ absl_numeric
+ PUBLIC_LIBRARIES
+ absl::int128
+ EXPORT_NAME
+ numeric
+)
+
+# test int128_test
+set(INT128_TEST_SRC "int128_test.cc")
+set(INT128_TEST_PUBLIC_LIBRARIES absl::numeric absl::base)
+
+absl_test(
+ TARGET
+ int128_test
+ SOURCES
+ ${INT128_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${INT128_TEST_PUBLIC_LIBRARIES}
+)
+
+
+
diff --git a/absl/strings/CMakeLists.txt b/absl/strings/CMakeLists.txt
new file mode 100644
index 00000000..dcd4974b
--- /dev/null
+++ b/absl/strings/CMakeLists.txt
@@ -0,0 +1,299 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+
+list(APPEND STRINGS_PUBLIC_HEADERS
+ "ascii.h"
+ "escaping.h"
+ "match.h"
+ "numbers.h"
+ "str_cat.h"
+ "string_view.h"
+ "strip.h"
+ "str_join.h"
+ "str_replace.h"
+ "str_split.h"
+ "substitute.h"
+)
+
+
+list(APPEND STRINGS_INTERNAL_HEADERS
+ "internal/char_map.h"
+ "internal/memutil.h"
+ "internal/ostringstream.h"
+ "internal/resize_uninitialized.h"
+ "internal/str_join_internal.h"
+ "internal/str_split_internal.h"
+ "internal/utf8.h"
+)
+
+
+
+# add string library
+list(APPEND STRINGS_SRC
+ "ascii.cc"
+ "escaping.cc"
+ "internal/memutil.cc"
+ "internal/memutil.h"
+ "internal/utf8.cc"
+ "match.cc"
+ "numbers.cc"
+ "str_cat.cc"
+ "str_replace.cc"
+ "str_split.cc"
+ "string_view.cc"
+ "substitute.cc"
+ ${STRINGS_PUBLIC_HEADERS}
+ ${STRINGS_INTERNAL_HEADERS}
+)
+set(STRINGS_PUBLIC_LIBRARIES absl::base absl_throw_delegate)
+
+absl_library(
+ TARGET
+ absl_strings
+ SOURCES
+ ${STRINGS_SRC}
+ PUBLIC_LIBRARIES
+ ${STRINGS_PUBLIC_LIBRARIES}
+ EXPORT_NAME
+ strings
+)
+
+
+#
+## TESTS
+#
+
+# test match_test
+set(MATCH_TEST_SRC "match_test.cc")
+set(MATCH_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ match_test
+ SOURCES
+ ${MATCH_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${MATCH_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test escaping_test
+set(ESCAPING_TEST_SRC "escaping_test.cc")
+set(ESCAPING_TEST_PUBLIC_LIBRARIES absl::strings absl::base)
+
+absl_test(
+ TARGET
+ escaping_test
+ SOURCES
+ ${ESCAPING_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${ESCAPING_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test ascii_test
+set(ASCII_TEST_SRC "ascii_test.cc")
+set(ASCII_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ ascii_test
+ SOURCES
+ ${ASCII_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${ASCII_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test memutil_test
+set(MEMUTIL_TEST_SRC "internal/memutil_test.cc")
+set(MEMUTIL_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ memutil_test
+ SOURCES
+ ${MEMUTIL_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${MEMUTIL_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test utf8_test
+set(UTF8_TEST_SRC "internal/utf8_test.cc")
+set(UTF8_TEST_PUBLIC_LIBRARIES absl::strings absl::base)
+
+absl_test(
+ TARGET
+ utf8_test
+ SOURCES
+ ${UTF8_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${UTF8_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test string_view_test
+set(STRING_VIEW_TEST_SRC "string_view_test.cc")
+set(STRING_VIEW_TEST_PUBLIC_LIBRARIES absl::strings absl_throw_delegate absl::base)
+
+absl_test(
+ TARGET
+ string_view_test
+ SOURCES
+ ${STRING_VIEW_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${STRING_VIEW_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test substitute_test
+set(SUBSTITUTE_TEST_SRC "substitute_test.cc")
+set(SUBSTITUTE_TEST_PUBLIC_LIBRARIES absl::strings absl::base)
+
+absl_test(
+ TARGET
+ substitute_test
+ SOURCES
+ ${SUBSTITUTE_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${SUBSTITUTE_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test str_replace_test
+set(STR_REPLACE_TEST_SRC "str_replace_test.cc")
+set(STR_REPLACE_TEST_PUBLIC_LIBRARIES absl::strings absl::base absl_throw_delegate)
+
+absl_test(
+ TARGET
+ str_replace_test
+ SOURCES
+ ${STR_REPLACE_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${STR_REPLACE_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test str_split_test
+set(STR_SPLIT_TEST_SRC "str_split_test.cc")
+set(STR_SPLIT_TEST_PUBLIC_LIBRARIES absl::strings absl::base absl_throw_delegate)
+
+absl_test(
+ TARGET
+ str_split_test
+ SOURCES
+ ${STR_SPLIT_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${STR_SPLIT_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test ostringstream_test
+set(OSTRINGSTREAM_TEST_SRC "internal/ostringstream_test.cc")
+
+absl_test(
+ TARGET
+ ostringstream_test
+ SOURCES
+ ${OSTRINGSTREAM_TEST_SRC}
+)
+
+
+# test resize_uninitialized_test
+set(RESIZE_UNINITIALIZED_TEST_SRC "internal/resize_uninitialized_test.cc")
+
+absl_test(
+ TARGET
+ resize_uninitialized_test
+ SOURCES
+ ${RESIZE_UNINITIALIZED_TEST_SRC}
+)
+
+
+# test str_join_test
+set(STR_JOIN_TEST_SRC "str_join_test.cc")
+set(STR_JOIN_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ str_join_test
+ SOURCES
+ ${STR_JOIN_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${STR_JOIN_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test str_cat_test
+set(STR_CAT_TEST_SRC "str_cat_test.cc")
+set(STR_CAT_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ str_cat_test
+ SOURCES
+ ${STR_CAT_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${STR_CAT_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test numbers_test
+set(NUMBERS_TEST_SRC "numbers_test.cc")
+set(NUMBERS_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ numbers_test
+ SOURCES
+ ${NUMBERS_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${NUMBERS_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test strip_test
+set(STRIP_TEST_SRC "strip_test.cc")
+set(STRIP_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ strip_test
+ SOURCES
+ ${STRIP_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${STRIP_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test char_map_test
+set(CHAR_MAP_TEST_SRC "internal/char_map_test.cc")
+set(CHAR_MAP_TEST_PUBLIC_LIBRARIES absl::strings)
+
+absl_test(
+ TARGET
+ char_map_test
+ SOURCES
+ ${CHAR_MAP_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${CHAR_MAP_TEST_PUBLIC_LIBRARIES}
+)
+
+
+
+
diff --git a/absl/synchronization/CMakeLists.txt b/absl/synchronization/CMakeLists.txt
new file mode 100644
index 00000000..c5c4c626
--- /dev/null
+++ b/absl/synchronization/CMakeLists.txt
@@ -0,0 +1,154 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND SYNCHRONIZATION_PUBLIC_HEADERS
+ "barrier.h"
+ "blocking_counter.h"
+ "mutex.h"
+ "notification.h"
+)
+
+
+list(APPEND SYNCHRONIZATION_INTERNAL_HEADERS
+ "internal/create_thread_identity.h"
+ "internal/graphcycles.h"
+ "internal/kernel_timeout.h"
+ "internal/per_thread_sem.h"
+ "internal/thread_pool.h"
+ "internal/waiter.h"
+)
+
+
+
+# syncrhonisation library
+list(APPEND SYNCHRONIZATION_SRC
+ "barrier.cc"
+ "blocking_counter.cc"
+ "internal/create_thread_identity.cc"
+ "internal/per_thread_sem.cc"
+ "internal/waiter.cc"
+ "internal/graphcycles.cc"
+ "notification.cc"
+ "mutex.cc"
+)
+set(SYNCHRONIZATION_PUBLIC_LIBRARIES absl::base absl_malloc_extension absl::time)
+
+absl_library(
+ TARGET
+ absl_synchronization
+ SOURCES
+ ${SYNCHRONIZATION_SRC}
+ PUBLIC_LIBRARIES
+ ${SYNCHRONIZATION_PUBLIC_LIBRARIES}
+ EXPORT_NAME
+ synchronization
+)
+
+
+#
+## TESTS
+#
+
+
+# test barrier_test
+set(BARRIER_TEST_SRC "barrier_test.cc")
+set(BARRIER_TEST_PUBLIC_LIBRARIES absl::synchronization)
+
+absl_test(
+ TARGET
+ barrier_test
+ SOURCES
+ ${BARRIER_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${BARRIER_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test blocking_counter_test
+set(BLOCKING_COUNTER_TEST_SRC "blocking_counter_test.cc")
+set(BLOCKING_COUNTER_TEST_PUBLIC_LIBRARIES absl::synchronization)
+
+absl_test(
+ TARGET
+ blocking_counter_test
+ SOURCES
+ ${BLOCKING_COUNTER_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${BLOCKING_COUNTER_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test graphcycles_test
+set(GRAPHCYCLES_TEST_SRC "internal/graphcycles_test.cc")
+set(GRAPHCYCLES_TEST_PUBLIC_LIBRARIES absl::synchronization)
+
+absl_test(
+ TARGET
+ graphcycles_test
+ SOURCES
+ ${GRAPHCYCLES_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${GRAPHCYCLES_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test mutex_test
+set(MUTEX_TEST_SRC "mutex_test.cc")
+set(MUTEX_TEST_PUBLIC_LIBRARIES absl::synchronization)
+
+absl_test(
+ TARGET
+ mutex_test
+ SOURCES
+ ${MUTEX_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${MUTEX_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test notification_test
+set(NOTIFICATION_TEST_SRC "notification_test.cc")
+set(NOTIFICATION_TEST_PUBLIC_LIBRARIES absl::synchronization)
+
+absl_test(
+ TARGET
+ notification_test
+ SOURCES
+ ${NOTIFICATION_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${NOTIFICATION_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test per_thread_sem_test_common
+set(PER_THREAD_SEM_TEST_COMMON_SRC "internal/per_thread_sem_test.cc")
+set(PER_THREAD_SEM_TEST_COMMON_PUBLIC_LIBRARIES absl::synchronization absl::strings)
+
+absl_test(
+ TARGET
+ per_thread_sem_test_common
+ SOURCES
+ ${PER_THREAD_SEM_TEST_COMMON_SRC}
+ PUBLIC_LIBRARIES
+ ${PER_THREAD_SEM_TEST_COMMON_PUBLIC_LIBRARIES}
+)
+
+
+
+
+
+
+
diff --git a/absl/time/CMakeLists.txt b/absl/time/CMakeLists.txt
new file mode 100644
index 00000000..60f61483
--- /dev/null
+++ b/absl/time/CMakeLists.txt
@@ -0,0 +1,78 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND TIME_PUBLIC_HEADERS
+ "clock.h"
+ "time.h"
+)
+
+
+list(APPEND TIME_INTERNAL_HEADERS
+ "internal/test_util.h"
+)
+
+list(APPEND TIME_SRC
+ "time.cc"
+ "clock.cc"
+ "duration.cc"
+ "format.cc"
+ ${TIME_PUBLIC_HEADERS}
+ ${TIME_INTERNAL_HEADERS}
+)
+set(TIME_PUBLIC_LIBRARIES absl::base absl::stacktrace absl::int128 cctz)
+
+absl_library(
+ TARGET
+ absl_time
+ SOURCES
+ ${TIME_SRC}
+ PUBLIC_LIBRARIES
+ ${TIME_PUBLIC_LIBRARIES}
+ PUBLIC_INCLUDE_DIRS
+ ${CCTZ_INCLUDE_DIRS}
+ EXPORT_NAME
+ time
+)
+
+
+
+#
+## TESTS
+#
+
+# test time_test
+list(APPEND TIME_TEST_SRC
+ "time_test.cc"
+ "clock_test.cc"
+ "duration_test.cc"
+ "format_test.cc"
+ "time_norm_test.cc"
+ "time_test.cc"
+ "time_zone_test.cc"
+ "internal/test_util.cc"
+)
+set(TIME_TEST_PUBLIC_LIBRARIES absl::time)
+
+absl_test(
+ TARGET
+ time_test
+ SOURCES
+ ${TIME_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${TIME_TEST_PUBLIC_LIBRARIES}
+)
+
+
diff --git a/absl/types/CMakeLists.txt b/absl/types/CMakeLists.txt
new file mode 100644
index 00000000..3e464497
--- /dev/null
+++ b/absl/types/CMakeLists.txt
@@ -0,0 +1,171 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+list(APPEND TYPES_PUBLIC_HEADERS
+ "any.h"
+ "bad_any_cast.h"
+ "bad_optional_access.h"
+ "optional.h"
+ "span.h"
+)
+
+
+# any library
+absl_header_library(
+ TARGET
+ absl_any
+ PUBLIC_LIBRARIES
+ absl::utility
+ EXPORT_NAME
+ any
+)
+
+# span library
+absl_header_library(
+ TARGET
+ absl_span
+ PUBLIC_LIBRARIES
+ absl::utility
+ EXPORT_NAME
+ span
+)
+
+
+# bad_any_cast library
+list(APPEND BAD_ANY_CAST_SRC
+ "bad_any_cast.cc"
+ ${TYPES_PUBLIC_HEADERS}
+)
+
+absl_library(
+ TARGET
+ absl_bad_any_cast
+ SOURCES
+ ${BAD_ANY_CAST_SRC}
+ PUBLIC_LIBRARIES
+ absl::base absl::any
+ EXPORT_NAME
+ bad_any_cast
+)
+
+
+# optional library
+list(APPEND OPTIONAL_SRC
+ "optional.cc"
+)
+
+absl_library(
+ TARGET
+ absl_optional
+ SOURCES
+ ${OPTIONAL_SRC}
+ PUBLIC_LIBRARIES
+ absl::base
+ EXPORT_NAME
+ optional
+)
+
+
+set(BAD_OPTIONAL_ACCESS_SRC "bad_optional_access.cc")
+set(BAD_OPTIONAL_ACCESS_LIBRARIES absl::base)
+
+absl_library(
+ TARGET
+ absl_bad_optional_access
+ SOURCES
+ ${BAD_OPTIONAL_ACCESS_SRC}
+ PUBLIC_LIBRARIES
+ ${BAD_OPTIONAL_ACCESS_PUBLIC_LIBRARIES}
+ EXPORT_NAME
+ bad_optional_access
+)
+
+
+
+#
+## TESTS
+#
+
+
+# test any_test
+set(ANY_TEST_SRC "any_test.cc")
+set(ANY_TEST_PUBLIC_LIBRARIES absl::base absl::throw_delegate absl::any absl::bad_any_cast test_instance_tracker_lib)
+
+absl_test(
+ TARGET
+ any_test
+ SOURCES
+ ${ANY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${ANY_TEST_PUBLIC_LIBRARIES}
+ PRIVATE_COMPILE_FLAGS
+ ${ABSL_EXCEPTIONS_FLAG}
+)
+
+
+# test any_test_noexceptions
+absl_test(
+ TARGET
+ any_test_noexceptions
+ SOURCES
+ ${ANY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${ANY_TEST_PUBLIC_LIBRARIES}
+)
+
+
+# test span_test
+set(SPAN_TEST_SRC "span_test.cc")
+set(SPAN_TEST_PUBLIC_LIBRARIES absl::base absl::strings absl::throw_delegate absl::span test_instance_tracker_lib)
+
+absl_test(
+ TARGET
+ span_test
+ SOURCES
+ ${SPAN_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${SPAN_TEST_PUBLIC_LIBRARIES}
+ PRIVATE_COMPILE_FLAGS
+ ${ABSL_EXCEPTIONS_FLAG}
+)
+
+
+# test span_test_noexceptions
+absl_test(
+ TARGET
+ span_test_noexceptions
+ SOURCES
+ ${SPAN_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${SPAN_TEST_PUBLIC_LIBRARIES}
+)
+
+
+
+# test optional_test
+set(OPTIONAL_TEST_SRC "optional_test.cc")
+set(OPTIONAL_TEST_PUBLIC_LIBRARIES absl::base absl::throw_delegate absl::optional absl_bad_optional_access)
+
+absl_test(
+ TARGET
+ optional_test
+ SOURCES
+ ${OPTIONAL_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${OPTIONAL_TEST_PUBLIC_LIBRARIES}
+)
+
+
diff --git a/absl/utility/CMakeLists.txt b/absl/utility/CMakeLists.txt
new file mode 100644
index 00000000..daf34178
--- /dev/null
+++ b/absl/utility/CMakeLists.txt
@@ -0,0 +1,60 @@
+#
+# Copyright 2017 The Abseil Authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+
+list(APPEND UTILITY_PUBLIC_HEADERS
+ "utility.h"
+)
+
+
+
+list(APPEND UTILITY_SRC
+ "utility.cc"
+ ${UTILITY_PUBLIC_HEADERS}
+)
+
+absl_library(
+ TARGET
+ absl_utility
+ SOURCES
+ ${UTILITY_SRC}
+ PUBLIC_LIBRARIES
+ ${UTILITY_PUBLIC_LIBRARIES}
+ EXPORT_NAME
+ utility
+)
+
+
+
+#
+## TESTS
+#
+
+# test utility_test
+set(UTILITY_TEST_SRC "utility_test.cc")
+set(UTILITY_TEST_PUBLIC_LIBRARIES absl::utility)
+
+absl_test(
+ TARGET
+ utility_test
+ SOURCES
+ ${UTILITY_TEST_SRC}
+ PUBLIC_LIBRARIES
+ ${UTILITY_TEST_PUBLIC_LIBRARIES}
+)
+
+
+