aboutsummaryrefslogtreecommitdiff
path: root/examples/CMakeLists.txt
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavi.dcr@tutanota.com>2024-09-07 00:04:38 +0200
committerXavier Del Campo Romero <xavi92@disroot.org>2025-11-06 14:38:40 +0100
commit6d9d80362f9932bbc87e162b8ef7df06c73e27e1 (patch)
treee3e228c63fe26f07503f226de7fb5086b3dc2286 /examples/CMakeLists.txt
downloadnanowasm-6d9d80362f9932bbc87e162b8ef7df06c73e27e1.tar.gz
First commit
Diffstat (limited to 'examples/CMakeLists.txt')
-rw-r--r--examples/CMakeLists.txt10
1 files changed, 10 insertions, 0 deletions
diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt
new file mode 100644
index 0000000..c182e37
--- /dev/null
+++ b/examples/CMakeLists.txt
@@ -0,0 +1,10 @@
+function(nw_example example)
+ add_executable(nw_${example} ${example}.c)
+ target_link_libraries(nw_${example} PRIVATE ${PROJECT_NAME})
+ install(TARGETS nw_${example})
+ target_compile_options(nw_${example} PRIVATE ${sup_cflags})
+endfunction()
+
+nw_example(minimal)
+nw_example(proc_exit)
+nw_example(file)