13ab18a62SMasahiro Yamada#!/bin/sh 23ab18a62SMasahiro Yamada# SPDX-License-Identifier: GPL-2.0-only 33ab18a62SMasahiro Yamada 43ab18a62SMasahiro Yamada# Set up CROSS_COMPILE if we are cross-compiling, but not called from the 53ab18a62SMasahiro Yamada# kernel toplevel Makefile 63ab18a62SMasahiro Yamadaif [ -z "${CROSS_COMPILE}${cross_compiling}" -a "${DEB_HOST_ARCH}" != "${DEB_BUILD_ARCH}" ]; then 73ab18a62SMasahiro Yamada echo CROSS_COMPILE=${DEB_HOST_GNU_TYPE}- 83ab18a62SMasahiro Yamadafi 93ab18a62SMasahiro Yamada 103ab18a62SMasahiro Yamadaversion=$(dpkg-parsechangelog -S Version) 11*7a531c21SMasahiro Yamadadebian_revision="${version##*-}" 123ab18a62SMasahiro Yamada 13*7a531c21SMasahiro Yamadaif [ "${version}" != "${debian_revision}" ]; then 143ab18a62SMasahiro Yamada echo KBUILD_BUILD_VERSION=${debian_revision} 15*7a531c21SMasahiro Yamadafi 16