From 2a8e7aeeef99161b6f0378ac14e297c23ca6227b Mon Sep 17 00:00:00 2001 From: Sebastiano Tronto Date: Wed, 4 Jun 2025 11:55:34 +0200 Subject: First 4 examples --- 00_hello_world/build.sh | 4 ++++ 00_hello_world/hello.c | 5 +++++ 00_hello_world/run-node.sh | 3 +++ 00_hello_world/run-server.sh | 3 +++ 4 files changed, 15 insertions(+) create mode 100755 00_hello_world/build.sh create mode 100644 00_hello_world/hello.c create mode 100755 00_hello_world/run-node.sh create mode 100755 00_hello_world/run-server.sh (limited to '00_hello_world') diff --git a/00_hello_world/build.sh b/00_hello_world/build.sh new file mode 100755 index 0000000..9b6b576 --- /dev/null +++ b/00_hello_world/build.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +mkdir -p build +emcc -o build/index.html hello.c diff --git a/00_hello_world/hello.c b/00_hello_world/hello.c new file mode 100644 index 0000000..66e36aa --- /dev/null +++ b/00_hello_world/hello.c @@ -0,0 +1,5 @@ +#include + +int main() { + printf("Hello, web!\n"); +} diff --git a/00_hello_world/run-node.sh b/00_hello_world/run-node.sh new file mode 100755 index 0000000..3fdf61e --- /dev/null +++ b/00_hello_world/run-node.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +node build/index.js diff --git a/00_hello_world/run-server.sh b/00_hello_world/run-server.sh new file mode 100755 index 0000000..c0087d4 --- /dev/null +++ b/00_hello_world/run-server.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +darkhttpd build -- cgit v1.3