Skip to content
Snippets Groups Projects
Select Git revision
  • fc308c93e147f653f5670568398eb897b319c81f
  • master default protected
2 results

zs5-multhr-hostcache

Blame
  • make.sh 1.79 KiB
    #!/bin/bash
    
    set -x
    
    # Nastaveni promennych, pokud je SINVERSION zakomentovana, pokusime se odhadnout nejnovejsi
    export DEBIAN_FRONTEND=noninteractive
    
    # Nacteni promennych o bezicim systemu vcetne verzi
    . /etc/os-release
    
    # Od Debian 11 Bullseye ma debian-security trochu jinou cestu, abychom mohli pouzit heredoc, rozskocime si pres funkci
    function get_debian_security() {
        if [ "${VERSION_ID}" -lt "11" ]; then echo "${VERSION_CODENAME}/updates"; else echo "${VERSION_CODENAME}-security"; fi
    }
    
    # Vygenerovani sources.list podle verze Debianu
    cat > /etc/apt/sources.list << EOSOURCES
    deb http://ftp.zcu.cz/pub/linux/debian ${VERSION_CODENAME} main contrib non-free
    deb http://ftp.zcu.cz/pub/linux/debian ${VERSION_CODENAME}-updates main contrib non-free
    deb http://ftp.zcu.cz/pub/linux/debian-security $(get_debian_security) main contrib non-free
    
    deb-src http://ftp.zcu.cz/pub/linux/debian ${VERSION_CODENAME} main contrib non-free
    deb-src http://ftp.zcu.cz/pub/linux/debian ${VERSION_CODENAME}-updates main contrib non-free
    deb-src http://ftp.zcu.cz/pub/linux/debian-security $(get_debian_security) main contrib non-free
    EOSOURCES
    
    # Instalace buildovacich veci a zavislosti
    apt update -qqq
    apt install -yqqq git devscripts build-essential
    
    
    apt source nfs-utils
    cd nfs-utils-1.3.4
    
    cp ../zs* debian/patches
    
    echo "zs1-local-realm-guess
    zs1-n-option-impl
    zs2-idmap-init
    #fixed-upstream zs2-keyutils
    zs3-keyctl-order
    zs4-nfs4mount-strtok
    zs5-multhr-hostcache
    zs5-add-missing-params.patch
    #fixed upstream zs5-thrsafe-strtok.patch
    zs6-krb-rc-param.patch
    zs7-svcgssdargs.patch" >> debian/patches/series
    
    dch --newversion "1.3.4-6+zs8" "Apply local patches"
    
    mk-build-deps --install --tool='apt-get -o Debug::pkgProblemResolver=yes --yes' debian/control
    
    # Build balicku
    dpkg-buildpackage -uc -us -b
    
    cd ..
    mkdir build
    mv *.deb build/