From 30c4906a52fb72ea43c33cf1bd4a139aa0f30839 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Sven=20Sch=C3=B6ling?= Date: Wed, 21 Jul 2010 12:29:15 +0200 Subject: [PATCH] DEBIAN paket generator ein wenig eingedampft. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Verzeichnisstruktur wird jetzt beim packen erzeugt, alle benötigten Dateien liegen unter DEBIAN/files. Verseion wird jetzt aus der VERSION Datei von Lx-Office geholt. --- DEBIAN/README | 8 +- DEBIAN/{usr/bin => files}/lx-office-erp | 0 .../man/man1 => files}/lx-office-erp.1.gz | Bin .../lx-office-erp.apache2.conf | 0 .../lx-office-erp.cherokee | 0 .../lx-office-erp.cherokee.handler | 0 DEBIAN/mk_erp_deb.sh | 72 +++++++++++++++++- DEBIAN/usr/lib/lx-office-erp/.dummy | 1 - DEBIAN/usr/lib/lx-office-erp/css | 1 - DEBIAN/usr/lib/lx-office-erp/doc | 1 - DEBIAN/usr/lib/lx-office-erp/image | 1 - DEBIAN/usr/lib/lx-office-erp/spool | 1 - DEBIAN/usr/lib/lx-office-erp/templates | 1 - DEBIAN/usr/lib/lx-office-erp/users | 1 - DEBIAN/usr/lib/lx-office-erp/webdav | 1 - DEBIAN/usr/lib/lx-office-erp/xslt | 1 - DEBIAN/usr/share/doc/lx-office-erp/.dummy | 1 - DEBIAN/usr/share/lx-office-erp/.dummy | 1 - DEBIAN/var/lib/lx-office-erp/css/.dummy | 1 - DEBIAN/var/lib/lx-office-erp/spool/.dummy | 1 - DEBIAN/var/lib/lx-office-erp/templates/.dummy | 1 - DEBIAN/var/lib/lx-office-erp/users/.dummy | 1 - .../lib/lx-office-erp/webdav/anfragen/.dummy | 1 - .../lib/lx-office-erp/webdav/angebote/.dummy | 1 - .../lx-office-erp/webdav/bestellungen/.dummy | 1 - .../webdav/einkaufsrechnungen/.dummy | 1 - .../lx-office-erp/webdav/gutschriften/.dummy | 1 - .../webdav/lieferantenbestellungen/.dummy | 1 - .../lx-office-erp/webdav/rechnungen/.dummy | 1 - DEBIAN/var/lib/lx-office-erp/xslt/.dummy | 1 - 30 files changed, 74 insertions(+), 29 deletions(-) rename DEBIAN/{usr/bin => files}/lx-office-erp (100%) rename DEBIAN/{usr/share/man/man1 => files}/lx-office-erp.1.gz (100%) rename DEBIAN/{etc/lx-office-erp => files}/lx-office-erp.apache2.conf (100%) rename DEBIAN/{etc/lx-office-erp => files}/lx-office-erp.cherokee (100%) rename DEBIAN/{etc/lx-office-erp => files}/lx-office-erp.cherokee.handler (100%) delete mode 100644 DEBIAN/usr/lib/lx-office-erp/.dummy delete mode 120000 DEBIAN/usr/lib/lx-office-erp/css delete mode 120000 DEBIAN/usr/lib/lx-office-erp/doc delete mode 120000 DEBIAN/usr/lib/lx-office-erp/image delete mode 120000 DEBIAN/usr/lib/lx-office-erp/spool delete mode 120000 DEBIAN/usr/lib/lx-office-erp/templates delete mode 120000 DEBIAN/usr/lib/lx-office-erp/users delete mode 120000 DEBIAN/usr/lib/lx-office-erp/webdav delete mode 120000 DEBIAN/usr/lib/lx-office-erp/xslt delete mode 100644 DEBIAN/usr/share/doc/lx-office-erp/.dummy delete mode 100644 DEBIAN/usr/share/lx-office-erp/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/css/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/spool/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/templates/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/users/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/anfragen/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/angebote/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/bestellungen/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/einkaufsrechnungen/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/gutschriften/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/lieferantenbestellungen/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/webdav/rechnungen/.dummy delete mode 100644 DEBIAN/var/lib/lx-office-erp/xslt/.dummy diff --git a/DEBIAN/README b/DEBIAN/README index f6156d8bf..39f0c1e65 100644 --- a/DEBIAN/README +++ b/DEBIAN/README @@ -4,9 +4,9 @@ ERP aus dem Git clonen: git clone git://lx-office.linet-services.de/lx-office-erp.git -Die Datei mk_erp_deb.sh -In das neue Verzeichnis lx-office-erp wechsel und die Datei -DEBIAN/mk_erp_deb.sh mit einem Editor öffnen. Die Pfade: -SRC und DEST ggf. anpassen und wieder speichern. +Die Datei mk_erp_deb.sh +In das neue Verzeichnis lx-office-erp wechsel und die Datei +DEBIAN/mk_erp_deb.sh mit einem Editor öffnen. Die Pfade: +SRC und DST ggf. anpassen und wieder speichern. Die Datei DEBIAN/mk_erp_deb.sh ausführen. Fertig. diff --git a/DEBIAN/usr/bin/lx-office-erp b/DEBIAN/files/lx-office-erp similarity index 100% rename from DEBIAN/usr/bin/lx-office-erp rename to DEBIAN/files/lx-office-erp diff --git a/DEBIAN/usr/share/man/man1/lx-office-erp.1.gz b/DEBIAN/files/lx-office-erp.1.gz similarity index 100% rename from DEBIAN/usr/share/man/man1/lx-office-erp.1.gz rename to DEBIAN/files/lx-office-erp.1.gz diff --git a/DEBIAN/etc/lx-office-erp/lx-office-erp.apache2.conf b/DEBIAN/files/lx-office-erp.apache2.conf similarity index 100% rename from DEBIAN/etc/lx-office-erp/lx-office-erp.apache2.conf rename to DEBIAN/files/lx-office-erp.apache2.conf diff --git a/DEBIAN/etc/lx-office-erp/lx-office-erp.cherokee b/DEBIAN/files/lx-office-erp.cherokee similarity index 100% rename from DEBIAN/etc/lx-office-erp/lx-office-erp.cherokee rename to DEBIAN/files/lx-office-erp.cherokee diff --git a/DEBIAN/etc/lx-office-erp/lx-office-erp.cherokee.handler b/DEBIAN/files/lx-office-erp.cherokee.handler similarity index 100% rename from DEBIAN/etc/lx-office-erp/lx-office-erp.cherokee.handler rename to DEBIAN/files/lx-office-erp.cherokee.handler diff --git a/DEBIAN/mk_erp_deb.sh b/DEBIAN/mk_erp_deb.sh index 306edd785..5856051cc 100755 --- a/DEBIAN/mk_erp_deb.sh +++ b/DEBIAN/mk_erp_deb.sh @@ -1,12 +1,80 @@ #!/bin/bash -VER="2.6.1" + #Jedes neue Paket der gleichen Version bekommt eine eigene Nummer NR="0" #hier wurde das Git-Paket entpakt: SRC=/tmp/lx-office-erp + #hier wird das Debian-Paket gebaut: -DEST=/tmp/lx-office/lx-office-erp_$VER-$NR-all +DST=/tmp/lx-office + + +################################################ +# ab hier keine Konfiguration mehr +################################################ + +VERSION=`cat ../VERSION` +DEST=$DST/lx-office-erp_$VER-$NR-all + +FILES=' +usr/lib/lx-office-erp/ +usr/share/lx-office-erp/ +usr/share/doc/lx-office-erp/ +var/lib/lx-office-erp/spool/ +var/lib/lx-office-erp/users/ +var/lib/lx-office-erp/css/ +var/lib/lx-office-erp/xslt/ +var/lib/lx-office-erp/templates/ +var/lib/lx-office-erp/webdav/lieferantenbestellungen/ +var/lib/lx-office-erp/webdav/anfragen/ +var/lib/lx-office-erp/webdav/gutschriften/ +var/lib/lx-office-erp/webdav/einkaufsrechnungen/ +var/lib/lx-office-erp/webdav/rechnungen/ +var/lib/lx-office-erp/webdav/bestellungen/ +var/lib/lx-office-erp/webdav/angebote/ +usr/lib/lx-office-erp/ +usr/share/lx-office-erp/ +usr/share/doc/lx-office-erp/ +usr/share/man/man1/:lx-office-erp.1.gz +etc/lx-office-erp/:lx-office-erp.cherokee.handler +etc/lx-office-erp/:lx-office-erp.apache2.conf +etc/lx-office-erp/:lx-office-erp.cherokee +usr/bin/:lx-office-erp +' + +for filespec in $FILES; do + set - `echo $filespec | sed -e 's/:/ /g'` + dir=$1 + file=$2 + + mkdir -p $dir + if [ -f "./files/$file" ]; then + cp ./files/$file $dir/$file + else + echo '1' > $dir/.dummy + fi +done + +SYMLINKS=' +css:/var/lib/lx-office-erp/css +doc:/usr/share/doc/lx-office-erp/ +image:/usr/share/lx-office-erp +spool:/var/lib/lx-office-erp/spool +templates:/var/lib/lx-office-erp/templates +users:/var/lib/lx-office-erp/users/ +webdav:/var/lib/lx-office-erp/webdav +xslt:/var/lib/lx-office-erp/xslt +' + +for symspec in $SYMLINKS; do + set - `echo $symspec | sed -e 's/:/ /g'` + src=$1 + tar=$2 + + ln -s $tar ./usr/lib/lx-office-erp/$src +done +#fertig mkdir -p $DEST cd $DEST diff --git a/DEBIAN/usr/lib/lx-office-erp/.dummy b/DEBIAN/usr/lib/lx-office-erp/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/usr/lib/lx-office-erp/css b/DEBIAN/usr/lib/lx-office-erp/css deleted file mode 120000 index f541bfe43..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/css +++ /dev/null @@ -1 +0,0 @@ -/var/lib/lx-office-erp/css \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/doc b/DEBIAN/usr/lib/lx-office-erp/doc deleted file mode 120000 index 05b8e11a1..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/doc +++ /dev/null @@ -1 +0,0 @@ -/usr/share/doc/lx-office-erp/ \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/image b/DEBIAN/usr/lib/lx-office-erp/image deleted file mode 120000 index 9d2627e47..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/image +++ /dev/null @@ -1 +0,0 @@ -/usr/share/lx-office-erp \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/spool b/DEBIAN/usr/lib/lx-office-erp/spool deleted file mode 120000 index a2386a82b..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/spool +++ /dev/null @@ -1 +0,0 @@ -/var/lib/lx-office-erp/spool \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/templates b/DEBIAN/usr/lib/lx-office-erp/templates deleted file mode 120000 index 156887ded..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/templates +++ /dev/null @@ -1 +0,0 @@ -/var/lib/lx-office-erp/templates \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/users b/DEBIAN/usr/lib/lx-office-erp/users deleted file mode 120000 index 1adc475c6..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/users +++ /dev/null @@ -1 +0,0 @@ -/var/lib/lx-office-erp/users/ \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/webdav b/DEBIAN/usr/lib/lx-office-erp/webdav deleted file mode 120000 index 4816277ed..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/webdav +++ /dev/null @@ -1 +0,0 @@ -/var/lib/lx-office-erp/webdav \ No newline at end of file diff --git a/DEBIAN/usr/lib/lx-office-erp/xslt b/DEBIAN/usr/lib/lx-office-erp/xslt deleted file mode 120000 index f85c349df..000000000 --- a/DEBIAN/usr/lib/lx-office-erp/xslt +++ /dev/null @@ -1 +0,0 @@ -/var/lib/lx-office-erp/xslt \ No newline at end of file diff --git a/DEBIAN/usr/share/doc/lx-office-erp/.dummy b/DEBIAN/usr/share/doc/lx-office-erp/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/usr/share/doc/lx-office-erp/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/usr/share/lx-office-erp/.dummy b/DEBIAN/usr/share/lx-office-erp/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/usr/share/lx-office-erp/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/css/.dummy b/DEBIAN/var/lib/lx-office-erp/css/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/css/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/spool/.dummy b/DEBIAN/var/lib/lx-office-erp/spool/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/spool/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/templates/.dummy b/DEBIAN/var/lib/lx-office-erp/templates/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/templates/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/users/.dummy b/DEBIAN/var/lib/lx-office-erp/users/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/users/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/anfragen/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/anfragen/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/anfragen/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/angebote/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/angebote/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/angebote/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/bestellungen/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/bestellungen/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/bestellungen/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/einkaufsrechnungen/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/einkaufsrechnungen/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/einkaufsrechnungen/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/gutschriften/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/gutschriften/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/gutschriften/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/lieferantenbestellungen/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/lieferantenbestellungen/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/lieferantenbestellungen/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/webdav/rechnungen/.dummy b/DEBIAN/var/lib/lx-office-erp/webdav/rechnungen/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/webdav/rechnungen/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/DEBIAN/var/lib/lx-office-erp/xslt/.dummy b/DEBIAN/var/lib/lx-office-erp/xslt/.dummy deleted file mode 100644 index d00491fd7..000000000 --- a/DEBIAN/var/lib/lx-office-erp/xslt/.dummy +++ /dev/null @@ -1 +0,0 @@ -1 -- 2.20.1