]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/blame - scripts/headers.sh
Merge tag 'ceph-for-4.8-rc2' of https://github.com/ceph/ceph-client
[mirror_ubuntu-zesty-kernel.git] / scripts / headers.sh
CommitLineData
2fb9b1bd
SR
1#!/bin/sh
2# Run headers_$1 command for all suitable architectures
3
4# Stop on error
5set -e
6
7do_command()
8{
9 if [ -f ${srctree}/arch/$2/include/asm/Kbuild ]; then
10 make ARCH=$2 KBUILD_HEADERS=$1 headers_$1
2fb9b1bd
SR
11 else
12 printf "Ignoring arch: %s\n" ${arch}
13 fi
14}
15
f6820308 16archs=${HDR_ARCH_LIST:-$(ls ${srctree}/arch)}
2fb9b1bd
SR
17
18for arch in ${archs}; do
19 case ${arch} in
20 um) # no userspace export
21 ;;
2fb9b1bd
SR
22 *)
23 if [ -d ${srctree}/arch/${arch} ]; then
24 do_command $1 ${arch}
25 fi
26 ;;
27 esac
28done