summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbuild9
-rw-r--r--dist-vars.sh14
-rw-r--r--src/etc/motd1
3 files changed, 20 insertions, 4 deletions
diff --git a/build b/build
index ef72cfd..8a47f95 100755
--- a/build
+++ b/build
@@ -8,7 +8,7 @@ version = $$(printf '%s\n' '$(OPK_SOURCE_VERSION)' | \
sed 's|\(^[0-9][0-9]*\.[0-9][0-9]*\).*$$|\1|')
script = \
- s|@DISTRIBUTION@|ProteanOS|; \
+ s|@DISTRIBUTION@|$${dist_name}|; \
s|@OS@|$(os)|; \
s|@VERSION@|$(version)|;
@@ -27,9 +27,12 @@ install: build
ln -s /run/lock base-files.data/var/lock
# Install base files.
set -e; \
+ . ../dist-vars.sh; \
+ printf "%s$${dist_motd_banner:+\n}\n" \
+ "$$(printf '%s' "$${dist_motd_banner}")" \
+ >base-files.data/etc/motd; \
sed ':l; N; $$!bl; s/\([^\n]\)\n\([^\n]\)/\1 \2/g' src/etc/motd | \
- sed "$(script)" | fold -s -w 72 >base-files.data/etc/motd
- set -e; \
+ sed "$(script)" | fold -s -w 72 >>base-files.data/etc/motd; \
for file in /etc/issue; do \
sed "$(script)" "src/$${file}" >"base-files.data/$${file}"; \
done
diff --git a/dist-vars.sh b/dist-vars.sh
new file mode 100644
index 0000000..36fd2fc
--- /dev/null
+++ b/dist-vars.sh
@@ -0,0 +1,14 @@
+# Distribution variables.
+
+dist_name='ProteanOS'
+dist_motd_banner="$(cat <<'EOF'
+ _
+ .' '.
+ __ ___ _ | |.'
+ | '. _ _ _|_ _ __ _ .' '. .' `- ~~| |~~~
+ |__.' |.' .' '. | .' '. _;. |' `. | | `-. ~~~~
+ | | | | | |---' .' | | | | | `.
+ | | '._.' '.- '._. '_.'| | | '.___.' `._.' TM
+EOF
+)"
+# A single quote to fix Vim syntax highlighting: '
diff --git a/src/etc/motd b/src/etc/motd
index fafa60e..03e8ff4 100644
--- a/src/etc/motd
+++ b/src/etc/motd
@@ -1,4 +1,3 @@
-
The programs included with @DISTRIBUTION@ @OS@ are free software; the
exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.