#!/bin/bash # Copyright (C) 2007-2010 Matías A. Fonzo, # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . set -e CWD=$(pwd) TMP=${TMP:-/tmp/sources} OUT=${OUT:-/tmp/packages} V=1.6 ARCH=noarch B=1 PKG=${TMP}/package-hierarchyfs rm -rf $PKG mkdir -p $PKG $OUT ( cd $PKG umask 000 lzip -cd ${CWD}/_hierarchyfs.tar.lz | tar -xf - ) cd $PKG cat ${CWD}/dragora-version > etc/dragora-version cat ${CWD}/README.media > media/README cat ${CWD}/README.mnt > mnt/README mkdir -p description for file in ${CWD}/description/* ; do cat $file > description/${file##*/} done makepkg ${OUT}/_hierarchyfs-${V}-${ARCH}-${B}.tlz