111 lines
5.7 KiB
Bash
111 lines
5.7 KiB
Bash
##############################################################################
|
|
# This optional file "builder-targets-cb.sh" will be called by builder.sh
|
|
#
|
|
# The targets will be called from thde opsi-builder using the following
|
|
# order: config, prepare, retrieve, create, package, publish, commit, cleanup
|
|
# You can overwrite the target functions in builder-targets-cb.sh
|
|
#
|
|
# You can define callback functions. The functions are called from
|
|
# opsi-builder within processing a target
|
|
# cb_package_makeproductfile
|
|
#
|
|
# You can use every variable defined in any configuration file or by
|
|
# the defined builder script itself. Also, calling the predefined
|
|
# targets builder_<targetname> is possible.
|
|
#
|
|
# Abstract:
|
|
# target order: config, prepare, retrieve, create, package, publish, commit, cleanup
|
|
# callbacks: <none>
|
|
#
|
|
##############################################################################
|
|
|
|
function cleanup() {
|
|
echo "Cleanup"
|
|
builder_cleanup
|
|
}
|
|
|
|
function create() {
|
|
echo "Create"
|
|
builder_create
|
|
rm $INST_DIR/CLIENT_DATA/*/DriversInstaller_Release_*_Full/*.url
|
|
mkdir -p $INST_DIR/CLIENT_DATA/X86_64/drivers
|
|
cp -al $INST_DIR/CLIENT_DATA/X86/drivers/Vista $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64/
|
|
rsync -avr $INST_DIR/CLIENT_DATA/X86/DriversInstaller_Release_*_Full/* $INST_DIR/CLIENT_DATA/X86
|
|
rsync -avr $INST_DIR/CLIENT_DATA/X86_64/DriversInstaller_Release_*_Full/* $INST_DIR/CLIENT_DATA/X86_64
|
|
rm -rf $INST_DIR/CLIENT_DATA/*/DriversInstaller_Release_*_Full/
|
|
|
|
################################################################################
|
|
# windows NT / 2000 / 2003 / Longhorn
|
|
#find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name AllNT -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name NTx64 -exec rm -rf {} \;
|
|
#find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name NTx86 -exec rm -rf {} \;
|
|
|
|
# Windows XP 32 / 64
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name AllXP -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name All5 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 5x86 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 5x64 -exec rm -rf {} \;
|
|
|
|
# Vista 32 / 64
|
|
#find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name All6 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 6x64 -exec rm -rf {} \;
|
|
#find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 6x86 -exec rm -rf {} \;
|
|
|
|
# Windows 7 32 / 64
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name All7 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 7x64 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 7x86 -exec rm -rf {} \;
|
|
|
|
# Windows 8 32 / 64
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name All8 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 8x64 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name 8x86 -exec rm -rf {} \;
|
|
|
|
# Windows Version Idependent
|
|
#find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name Allx86 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers/Vista -type d -name Allx64 -exec rm -rf {} \;
|
|
|
|
# delete empty dirs
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers -type d -empty -exec rmdir {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers -type d -empty -exec rmdir {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers -type d -empty -exec rmdir {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86/drivers -type d -empty -exec rmdir {} \;
|
|
|
|
################################################################################
|
|
# windows NT / 2000 / 2003 / Longhorn
|
|
#find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name AllNT -exec rm -rf {} \;
|
|
#find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name NTx64 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name NTX86 -exec rm -rf {} \;
|
|
|
|
# Windows XP 32 / 64
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name All5 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 5x86 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 5x64 -exec rm -rf {} \;
|
|
|
|
# Vista 32 / 64
|
|
#find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name All6 -exec rm -rf {} \;
|
|
#find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 6x64 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 6x86 -exec rm -rf {} \;
|
|
|
|
# Windows 7 32 / 64
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name All7 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 7x64 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 7x86 -exec rm -rf {} \;
|
|
|
|
# Windows 8 32 / 64
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name All8 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 8x64 -exec rm -rf {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name 8x86 -exec rm -rf {} \;
|
|
|
|
# Windows Version Idependent
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name Allx86 -exec rm -rf {} \;
|
|
#find $INST_DIR/CLIENT_DATA/X86_64/drivers/Vista64 -type d -name Allx64 -exec rm -rf {} \;
|
|
|
|
# delete empty dirs
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers -type d -empty -exec rmdir {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers -type d -empty -exec rmdir {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers -type d -empty -exec rmdir {} \;
|
|
find $INST_DIR/CLIENT_DATA/X86_64/drivers -type d -empty -exec rmdir {} \;
|
|
}
|
|
|