From fa723e4da09f5980f540096bf471456f72f3b7c4 Mon Sep 17 00:00:00 2001 From: mike lowis Date: Fri, 9 Apr 2021 22:28:07 -0400 Subject: [PATCH] remove unused stuff from install scripts --- CONFIG.bak | 5 ----- install | 49 +------------------------------------------------ 2 files changed, 1 insertion(+), 53 deletions(-) delete mode 100644 CONFIG.bak diff --git a/CONFIG.bak b/CONFIG.bak deleted file mode 100644 index b1a6bfc..0000000 --- a/CONFIG.bak +++ /dev/null @@ -1,5 +0,0 @@ -prefix=/usr/local -libdir=lib -cIntType=int -cRealType=double -version=0.16.1 diff --git a/install b/install index 83c5c5c..8c0de79 100755 --- a/install +++ b/install @@ -25,10 +25,8 @@ readonly libdir="$(awk -F '=' '$1 == "libdir" { print $2; }' CONFIG)" destdir= includeLibCSrc=false -readonly scripts="obncdoc-extract obncdoc-index obncdoc-markup" readonly basicModules="Files In Input Input0 Math Out Strings XYplane" -readonly docFiles="oberon-report.html" -readonly man1Files="obnc.1 obnc-compile.1 obnc-path.1 obncdoc.1" +readonly man1Files="obnc.1 obnc-compile.1" EchoAndRun() { @@ -43,15 +41,7 @@ Install() EchoAndRun mkdir -p "$destdir$prefix/bin" EchoAndRun cp "bin/obnc" "$destdir$prefix/bin" EchoAndRun cp "bin/obnc-compile" "$destdir$prefix/bin" - EchoAndRun cp "bin/obnc-path" "$destdir$prefix/bin" - EchoAndRun cp "bin/obncdoc" "$destdir$prefix/bin" local file= - for file in $scripts; do - EchoAndRun sed -e '"s|^\(readonly defaultPrefix=\).*$|\1'"'$prefix'"'|"' \ - -e '"s|^\(readonly defaultLibDir=\).*$|\1'"'$libdir'"'|"' \ - '"bin/'$file'"' \> '"'$destdir$prefix/bin/$file'"' - EchoAndRun chmod +x "$destdir$prefix/bin/$file" - done EchoAndRun mkdir -p "$destdir$prefix/include/obnc" EchoAndRun cp "lib/obnc/OBNCConfig.h" "$destdir$prefix/include/obnc" EchoAndRun cp "lib/obnc/OBNC.h" "$destdir$prefix/include/obnc" @@ -86,31 +76,11 @@ Install() done rm -r "lib/obnc/.obnc" - #install documentation - EchoAndRun mkdir -p "$destdir$prefix/share/doc/obnc" - for file in $docFiles; do - EchoAndRun cp "share/doc/obnc/$file" "$destdir$prefix/share/doc/obnc" - done - (cd "lib/obnc" && OBNC_PREFIX="$selfDirPath" ../../bin/obncdoc) - EchoAndRun mkdir -p "$destdir$prefix/share/doc/obnc/obncdoc/obnc" - for file in "lib/obnc/obncdoc"/*; do - EchoAndRun cp "$file" "$destdir$prefix/share/doc/obnc/obncdoc/obnc" - done - EchoAndRun cd "$destdir$prefix/share/doc/obnc/obncdoc" - EchoAndRun "$selfDirPath/bin/obncdoc-index" \> index.html - EchoAndRun cp "$selfDirPath/share/obnc/style.css" . - cd - >/dev/null - rm -r lib/obnc/obncdoc - #install man pages EchoAndRun mkdir -p "$destdir$prefix/share/man/man1" for file in $man1Files; do EchoAndRun cp "share/man/man1/$file" "$destdir$prefix/share/man/man1" done - - #install obncdoc style file - EchoAndRun mkdir -p "$destdir$prefix/share/obnc" - EchoAndRun cp "$selfDirPath/share/obnc/style.css" "$destdir$prefix/share/obnc" } @@ -119,12 +89,6 @@ Uninstall() #delete executables EchoAndRun rm -f "$destdir$prefix/bin/obnc" EchoAndRun rm -f "$destdir$prefix/bin/obnc-compile" - EchoAndRun rm -f "$destdir$prefix/bin/obnc-path" - EchoAndRun rm -f "$destdir$prefix/bin/obncdoc" - local file= - for file in $scripts; do - EchoAndRun rm -f "$destdir$prefix/bin/$file" - done #delete library files local module= @@ -142,21 +106,10 @@ Uninstall() EchoAndRun rm -f "$destdir$prefix/$libdir/obnc/OBNC.env" EchoAndRun rm -f "$destdir$prefix/$libdir/obnc/OBNC.c" - #delete documentation - for file in $docFiles; do - EchoAndRun rm -f "$destdir$prefix/share/doc/obnc/$file" - done - EchoAndRun rm -f "$destdir$prefix/share/doc/obnc/obncdoc/obnc/"* - EchoAndRun rm -f "$destdir$prefix/share/doc/obnc/obncdoc/index.html" - EchoAndRun rm -f "$destdir$prefix/share/doc/obnc/obncdoc/style.css" - #delete man pages for file in $man1Files; do EchoAndRun rm -f "$destdir$prefix/share/man/man1/$file" done - - #delete obncdoc style file - EchoAndRun rm -f "$destdir$prefix/share/obnc/style.css" } -- 2.49.0