diff --git a/Makefile.am b/Makefile.am index 88d42fc88..00f6ba241 100644 --- a/Makefile.am +++ b/Makefile.am @@ -31,6 +31,7 @@ include $(abs_top_nlbuild_autotools_dir)/automake/pre.am AM_MAKEFLAGS = --no-print-directory SUBDIRS = \ + include \ src \ third_party \ examples \ diff --git a/configure.ac b/configure.ac index ea03e4ee0..30d11cf51 100644 --- a/configure.ac +++ b/configure.ac @@ -416,6 +416,9 @@ NL_RESTORE_WERROR # AC_CONFIG_FILES([ Makefile +include/Makefile +include/crypto/Makefile +include/platform/Makefile src/Makefile src/cli/Makefile src/core/Makefile diff --git a/doc/Makefile.am b/doc/Makefile.am index 4d9555e1b..8b17ce701 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -30,7 +30,10 @@ include $(abs_top_nlbuild_autotools_dir)/automake/pre.am EXTRA_DIST = \ $(srcdir)/Doxyfile.in \ - $(srcdir)/index.dox \ + $(srcdir)/header.html \ + $(srcdir)/images/Open-Thread-Logo-200x42.png \ + $(srcdir)/images/openthread_contrib.png \ + $(srcdir)/images/openthread_logo.png \ $(NULL) # @@ -45,18 +48,18 @@ VERSION = $(PACKAGE_VERSION) docdistdir ?= . -openthread_docdist_alias = \ +openthread_docdist_alias = \ $(PACKAGE_TARNAME)-docs -openthread_docdist_name = \ +openthread_docdist_name = \ $(openthread_docdist_alias)-$(VERSION) -openthread_docdist_archive = \ +openthread_docdist_archive = \ $(docdistdir)/$(openthread_docdist_name).tar.gz CLEANFILES = \ Doxyfile \ - $(openthread_docdist_archive) \ + $(openthread_docdist_archive) \ $(NULL) if OPENTHREAD_BUILD_DOCS diff --git a/examples/platform/Makefile.am b/examples/platform/Makefile.am index 96016a05f..df403e06d 100644 --- a/examples/platform/Makefile.am +++ b/examples/platform/Makefile.am @@ -40,6 +40,4 @@ SUBDIRS = \ posix \ $(NULL) -all: - include $(abs_top_nlbuild_autotools_dir)/automake/post.am diff --git a/examples/platform/posix/Makefile.am b/examples/platform/posix/Makefile.am index b01bc41ea..82583d965 100644 --- a/examples/platform/posix/Makefile.am +++ b/examples/platform/posix/Makefile.am @@ -61,6 +61,8 @@ libopenthread_posix_a_SOURCES = \ $(NULL) include_HEADERS = \ + cmdline.h \ + platform.h \ $(NULL) install-headers: install-includeHEADERS diff --git a/include/Makefile.am b/include/Makefile.am new file mode 100644 index 000000000..f6fdf31a0 --- /dev/null +++ b/include/Makefile.am @@ -0,0 +1,52 @@ +# +# Copyright (c) 2016, Nest Labs, Inc. +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# 3. Neither the name of the copyright holder nor the +# names of its contributors may be used to endorse or promote products +# derived from this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE +# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +# POSSIBILITY OF SUCH DAMAGE. +# + +include $(abs_top_nlbuild_autotools_dir)/automake/pre.am + +# Always package (e.g. for 'make dist') these subdirectories. + +DIST_SUBDIRS = \ + crypto \ + platform \ + $(NULL) + +# Always build (e.g. for 'make all') these subdirectories. + +SUBDIRS = \ + crypto \ + platform \ + $(NULL) + +include_HEADERS = \ + openthread.h \ + openthread-types.h \ + $(NULL) + +install-headers: install-includeHEADERS + +include $(abs_top_nlbuild_autotools_dir)/automake/post.am diff --git a/include/crypto/Makefile.am b/include/crypto/Makefile.am new file mode 100644 index 000000000..554158469 --- /dev/null +++ b/include/crypto/Makefile.am @@ -0,0 +1,38 @@ +# +# Copyright (c) 2016, Nest Labs, Inc. +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# 3. Neither the name of the copyright holder nor the +# names of its contributors may be used to endorse or promote products +# derived from this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE +# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +# POSSIBILITY OF SUCH DAMAGE. +# + +include $(abs_top_nlbuild_autotools_dir)/automake/pre.am + +include_HEADERS = \ + aes_ecb.h \ + hmac_sha256.h \ + $(NULL) + +install-headers: install-includeHEADERS + +include $(abs_top_nlbuild_autotools_dir)/automake/post.am diff --git a/include/platform/Makefile.am b/include/platform/Makefile.am new file mode 100644 index 000000000..bccd6efb9 --- /dev/null +++ b/include/platform/Makefile.am @@ -0,0 +1,42 @@ +# +# Copyright (c) 2016, Nest Labs, Inc. +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# 3. Neither the name of the copyright holder nor the +# names of its contributors may be used to endorse or promote products +# derived from this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE +# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +# POSSIBILITY OF SUCH DAMAGE. +# + +include $(abs_top_nlbuild_autotools_dir)/automake/pre.am + +include_HEADERS = \ + atomic.h \ + alarm.h \ + logging.h \ + radio.h \ + random.h \ + serial.h \ + $(NULL) + +install-headers: install-includeHEADERS + +include $(abs_top_nlbuild_autotools_dir)/automake/post.am diff --git a/src/Makefile.am b/src/Makefile.am index 094477e26..142cc0460 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -42,6 +42,4 @@ SUBDIRS = \ core \ $(NULL) -all: - include $(abs_top_nlbuild_autotools_dir)/automake/post.am diff --git a/src/cli/Makefile.am b/src/cli/Makefile.am index e82d7f29d..1549a61d9 100644 --- a/src/cli/Makefile.am +++ b/src/cli/Makefile.am @@ -42,11 +42,13 @@ libopenthread_cli_a_SOURCES = \ cli_serial.cpp \ $(NULL) -include_HEADERS = \ +noinst_HEADERS = \ + cli.hpp \ + cli_serial.hpp \ + cli_server.hpp \ + cli_udp.hpp \ $(NULL) -install-headers: install-includeHEADERS - if OPENTHREAD_BUILD_COVERAGE CLEANFILES = $(wildcard *.gcda *.gcno) endif # OPENTHREAD_BUILD_COVERAGE diff --git a/src/core/Makefile.am b/src/core/Makefile.am index 5d70d864a..0a5221a48 100644 --- a/src/core/Makefile.am +++ b/src/core/Makefile.am @@ -68,11 +68,47 @@ libopenthread_a_SOURCES = \ thread/thread_tlvs.cpp \ $(NULL) -include_HEADERS = \ +noinst_HEADERS = \ + openthread-core-config.h \ + coap/coap_header.hpp \ + coap/coap_server.hpp \ + common/code_utils.hpp \ + common/debug.hpp \ + common/encoding.hpp \ + common/logging.hpp \ + common/message.hpp \ + common/tasklet.hpp \ + common/timer.hpp \ + crypto/aes_ccm.hpp \ + mac/mac.hpp \ + mac/mac_frame.hpp \ + mac/mac_whitelist.hpp \ + net/icmp6.hpp \ + net/ip6.hpp \ + net/ip6_address.hpp \ + net/ip6_mpl.hpp \ + net/ip6_routes.hpp \ + net/netif.hpp \ + net/socket.hpp \ + net/udp6.hpp \ + thread/address_resolver.hpp \ + thread/key_manager.hpp \ + thread/lowpan.hpp \ + thread/mesh_forwarder.hpp \ + thread/mle.hpp \ + thread/mle_constants.hpp \ + thread/mle_router.hpp \ + thread/mle_tlvs.hpp \ + thread/network_data.hpp \ + thread/network_data_leader.hpp \ + thread/network_data_local.hpp \ + thread/network_data_tlvs.hpp \ + thread/thread_netif.hpp \ + thread/thread_tlvs.hpp \ + thread/thread_uris.hpp \ + thread/topology.hpp \ $(NULL) -install-headers: install-includeHEADERS - if OPENTHREAD_BUILD_COVERAGE CLEANFILES = $(wildcard *.gcda *.gcno) endif # OPENTHREAD_BUILD_COVERAGE diff --git a/tests/Makefile.am b/tests/Makefile.am index 81c2cdcf9..72709fd09 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -42,8 +42,6 @@ SUBDIRS = \ unit \ $(NULL) -all: - if OPENTHREAD_BUILD_TESTS if OPENTHREAD_BUILD_COVERAGE CLEANFILES = $(wildcard *.gcda *.gcno) diff --git a/tests/scripts/Makefile.am b/tests/scripts/Makefile.am index 6deb3b42a..1342bd305 100644 --- a/tests/scripts/Makefile.am +++ b/tests/scripts/Makefile.am @@ -28,19 +28,80 @@ include $(abs_top_nlbuild_autotools_dir)/automake/pre.am -# Always package (e.g. for 'make dist') these subdirectories. - -DIST_SUBDIRS = \ - thread-cert \ +EXTRA_DIST = \ + thread-cert/Cert_5_1_01_RouterAttach.py \ + thread-cert/Cert_5_1_02_ChildAddressTimeout.py \ + thread-cert/Cert_5_1_03_RouterAddressReallocation.py \ + thread-cert/Cert_5_1_04_RouterAddressReallocation.py \ + thread-cert/Cert_5_1_05_RouterAddressTimeout.py \ + thread-cert/Cert_5_1_06_RemoveRouterId.py \ + thread-cert/Cert_5_1_07_MaxChildCount.py \ + thread-cert/Cert_5_1_08_RouterAttachConnectivity.py \ + thread-cert/Cert_5_1_09_REEDAttachConnectivity.py \ + thread-cert/Cert_5_1_10_RouterAttachLinkQuality.py \ + thread-cert/Cert_5_1_11_REEDAttachLinkQuality.py \ + thread-cert/Cert_5_1_12_NewRouterNeighborSync.py \ + thread-cert/Cert_5_1_13_RouterReset.py \ + thread-cert/Cert_5_2_01_BecomeActiveRouter.py \ + thread-cert/Cert_5_2_02_LeaderReject1Hop.py \ + thread-cert/Cert_5_2_03_LeaderReject2Hops.py \ + thread-cert/Cert_5_2_04_REEDUpgrade.py \ + thread-cert/Cert_5_2_05_AddressQuery.py \ + thread-cert/Cert_5_2_07_REEDSynchronization.py \ + thread-cert/Cert_5_3_01_LinkLocal.py \ + thread-cert/Cert_5_3_02_RealmLocal.py \ + thread-cert/Cert_5_3_03_AddressQuery.py \ + thread-cert/Cert_5_3_04_AddressMapCache.py \ + thread-cert/Cert_5_3_05_RoutingLinkQuality.py \ + thread-cert/Cert_5_3_06_RouterIdMask.py \ + thread-cert/Cert_5_3_07_DuplicateAddress.py \ + thread-cert/Cert_5_3_08_ChildAddressSet.py \ + thread-cert/Cert_5_3_10_AddressQuery.py \ + thread-cert/Cert_5_5_01_LeaderReset.py \ + thread-cert/Cert_5_5_02_LeaderReboot.py \ + thread-cert/Cert_5_5_03_SplitMergeChildren.py \ + thread-cert/Cert_5_5_04_SplitMergeRouters.py \ + thread-cert/Cert_5_5_05_SplitMergeREED.py \ + thread-cert/Cert_5_5_06_SplitWeight.py \ + thread-cert/Cert_5_5_07_SplitMergeThreeWay.py \ + thread-cert/Cert_5_5_08_SplitRoutersLostLeader.py \ + thread-cert/Cert_5_6_01_NetworkDataRegisterBeforeAttachLeader.py \ + thread-cert/Cert_5_6_02_NetworkDataRegisterBeforeAttachRouter.py \ + thread-cert/Cert_5_6_03_NetworkDataRegisterAfterAttachLeader.py \ + thread-cert/Cert_5_6_04_NetworkDataRegisterAfterAttachRouter.py \ + thread-cert/Cert_5_6_05_NetworkDataRegisterAfterAttachRouter.py \ + thread-cert/Cert_5_6_06_NetworkDataExpiration.py \ + thread-cert/Cert_5_6_07_NetworkDataRequestREED.py \ + thread-cert/Cert_5_6_08_ContextManagement.py \ + thread-cert/Cert_5_6_09_NetworkDataForwarding.py \ + thread-cert/Cert_5_8_01_KeySynchronization.py \ + thread-cert/Cert_5_8_02_KeyIncrement.py \ + thread-cert/Cert_5_8_03_KeyIncrementRollOver.py \ + thread-cert/Cert_6_1_01_RouterAttach.py \ + thread-cert/Cert_6_1_02_REEDAttach.py \ + thread-cert/Cert_6_1_03_RouterAttachConnectivity.py \ + thread-cert/Cert_6_1_04_REEDAttachConnectivity.py \ + thread-cert/Cert_6_1_05_RouterAttachLinkQuality.py \ + thread-cert/Cert_6_1_06_REEDAttachLinkQuality.py \ + thread-cert/Cert_6_1_07_EDSynchronization.py \ + thread-cert/Cert_6_2_01_NewPartition.py \ + thread-cert/Cert_6_2_02_NewPartition.py \ + thread-cert/Cert_6_3_01_OrphanReattach.py \ + thread-cert/Cert_6_3_02_NetworkDataUpdate.py \ + thread-cert/Cert_6_4_01_LinkLocal.py \ + thread-cert/Cert_6_4_02_RealmLocal.py \ + thread-cert/Cert_6_5_01_ChildResetSynchronize.py \ + thread-cert/Cert_6_5_02_ChildResetReattach.py \ + thread-cert/Cert_6_6_01_KeyIncrement.py \ + thread-cert/Cert_6_6_02_KeyIncrementRollOver.py \ + thread-cert/Cert_7_1_01_BorderRouterAsLeader.py \ + thread-cert/Cert_7_1_02_BorderRouterAsRouter.py \ + thread-cert/Cert_7_1_03_BorderRouterAsLeader.py \ + thread-cert/Cert_7_1_04_BorderRouterAsRouter.py \ + thread-cert/Cert_7_1_05_BorderRouterAsRouter.py \ + thread-cert/node.py \ $(NULL) -# Always build (e.g. for 'make all') these subdirectories. - -SUBDIRS = \ - $(NULL) - -all: - if OPENTHREAD_BUILD_TESTS # First, list all essential program and script tests that MUST be run. diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am index d48ded75e..c83dc9df2 100644 --- a/tests/unit/Makefile.am +++ b/tests/unit/Makefile.am @@ -33,6 +33,7 @@ include $(abs_top_nlbuild_autotools_dir)/automake/pre.am # since they are not part of the package. # noinst_HEADERS = \ + test_util.h \ $(NULL) # diff --git a/third_party/Makefile.am b/third_party/Makefile.am index 79e3ba379..f26c54fa7 100644 --- a/third_party/Makefile.am +++ b/third_party/Makefile.am @@ -40,6 +40,4 @@ SUBDIRS = \ mbedtls \ $(NULL) -all: - include $(abs_top_nlbuild_autotools_dir)/automake/post.am