Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix some configuration differences between GN & automake #1582

Merged
merged 1 commit into from
Jul 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions config/standalone/args.gni
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# Options from standalone-chip.mk that differ from configure defaults. These
# options are used from examples/.
chip_build_tests = false

config_network_layer_ble = false
inet_config_enable_async_dns_sockets = false

project_config_include_dirs = rebase_path([ "." ])
chip_project_config_include = "<CHIPProjectConfig.h>"
system_project_config_include = "<SystemProjectConfig.h>"
inet_config_enable_tun_endpoint = false
inet_config_enable_raw_endpoint = false
inet_config_enable_dns_resolver = false
8 changes: 8 additions & 0 deletions src/lib/support/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,14 @@ static_library("support") {
"${nlassert_root}:nlassert",
]

# These are needed because we include CHIPCore.h, which uses config
# options for src/ble and src/inet, however we cannot depend on those
# directly as such a dependency is cyclic.
public_deps += [
"${chip_root}/src/ble:ble_config_header",
"${chip_root}/src/inet:inet_config_header",
]

public_configs = [ ":support_config" ]

if (chip_config_memory_management == "simple") {
Expand Down
10 changes: 8 additions & 2 deletions src/system/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ import("system.gni")
declare_args() {
# Extra header to include in CHIPConfig.h for project.
# TODO - This should probably be in src/core but src/system also uses it.
chip_project_config_include = ""
chip_project_config_include = "<CHIPProjectConfig.h>"

# Extra header to include in CHIPConfig.h for platform.
# TODO - This should probably be in src/core but src/system also uses it.
chip_platform_config_include = ""

# Extra header to include in SystemConfig.h for project.
system_project_config_include = ""
system_project_config_include = "<SystemProjectConfig.h>"

# Extra header to include in SystemConfig.h for platform.
system_platform_config_include = ""
Expand All @@ -38,6 +38,12 @@ declare_args() {
project_config_include_dirs = []
}

if (project_config_include_dirs == [] &&
chip_project_config_include == "<CHIPProjectConfig.h>" &&
system_project_config_include == "<SystemProjectConfig.h>") {
project_config_include_dirs += [ "${chip_root}/config/standalone" ]
}

config("system_config") {
configs = [ "${chip_root}/src:includes" ]

Expand Down