Whamcloud - gitweb
LU-11004 ptlrpc: Serialize procfs access to scp_hist_reqs using mutex
[fs/lustre-release.git] / lustre-dkms_post-build.sh
1 #!/bin/bash
2 # $1 : $module
3 # $2 : $module_version
4 # $3 : $kernelver
5 # $4 : $kernel_source_dir
6 # $5 : $arch
7 # $6 : $source_tree
8 # $7 : $dkms_tree
9 #
10 # This script ensure that ALL Lustre kernel modules that have been built
11 # during DKMS build step of lustre[-client]-dkms module will be moved in
12 # DKMS vault/repository, and this before the build directory content will be
13 # trashed.
14 # This is required because dkms.conf file is only sourced at the very
15 # beginning of the DKMS build step when its content has to be on-target
16 # customized during pre_build script. This can lead to incomplete list
17 # of built Lustre kernel modules then to be saved for next DKMS install step.
18
19 # Use this place to also save config.log that has been generated during
20 # pre_build.
21 # $7/$1/$2/$3/$5/log repository should have already been created to save
22 # make.log and $kernel_config
23 mkdir -p "$7/$1/$2/$3/$5/log"
24 cp -f "$7/$1/$2/build/config.log" "$7/$1/$2/$3/$5/log/config.log" 2>/dev/null
25 cp -f "$7/$1/$2/build/config.h" \
26     "$7/$1/$2/build/Module.symvers" \
27     "$7/$1/$2/$3/$5/" 2> /dev/null