From 7b6e527f440cd7e6f8be2b07cee320ee6ca18786 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 29 Apr 2024 06:41:38 +0200 Subject: Adding upstream version 1.0.1. Signed-off-by: Daniel Baumann --- test cases/swift/7 modulemap subdir/mylib/meson.build | 4 ++++ test cases/swift/7 modulemap subdir/mylib/module.modulemap | 5 +++++ test cases/swift/7 modulemap subdir/mylib/mylib.c | 5 +++++ test cases/swift/7 modulemap subdir/mylib/mylib.h | 3 +++ 4 files changed, 17 insertions(+) create mode 100644 test cases/swift/7 modulemap subdir/mylib/meson.build create mode 100644 test cases/swift/7 modulemap subdir/mylib/module.modulemap create mode 100644 test cases/swift/7 modulemap subdir/mylib/mylib.c create mode 100644 test cases/swift/7 modulemap subdir/mylib/mylib.h (limited to 'test cases/swift/7 modulemap subdir/mylib') diff --git a/test cases/swift/7 modulemap subdir/mylib/meson.build b/test cases/swift/7 modulemap subdir/mylib/meson.build new file mode 100644 index 0000000..2549e2b --- /dev/null +++ b/test cases/swift/7 modulemap subdir/mylib/meson.build @@ -0,0 +1,4 @@ + +i = include_directories('.') +lib = static_library('mylib', 'mylib.c') +dep = declare_dependency(include_directories : i, link_with : lib) diff --git a/test cases/swift/7 modulemap subdir/mylib/module.modulemap b/test cases/swift/7 modulemap subdir/mylib/module.modulemap new file mode 100644 index 0000000..5aab62e --- /dev/null +++ b/test cases/swift/7 modulemap subdir/mylib/module.modulemap @@ -0,0 +1,5 @@ +module mylib [extern_c] { + header "mylib.h" + link "mylib" + export * +} diff --git a/test cases/swift/7 modulemap subdir/mylib/mylib.c b/test cases/swift/7 modulemap subdir/mylib/mylib.c new file mode 100644 index 0000000..e091836 --- /dev/null +++ b/test cases/swift/7 modulemap subdir/mylib/mylib.c @@ -0,0 +1,5 @@ +#include"mylib.h" + +int getNumber() { + return 42; +} diff --git a/test cases/swift/7 modulemap subdir/mylib/mylib.h b/test cases/swift/7 modulemap subdir/mylib/mylib.h new file mode 100644 index 0000000..21bd9eb --- /dev/null +++ b/test cases/swift/7 modulemap subdir/mylib/mylib.h @@ -0,0 +1,3 @@ +#pragma once + +int getNumber(); -- cgit v1.2.3