11476fee5SMasahiro Yamada#!/bin/sh 21476fee5SMasahiro Yamada 31476fee5SMasahiro Yamadaset -e 41476fee5SMasahiro Yamada 51476fee5SMasahiro Yamada# When you move, remove or rename generated files, you probably also update 61476fee5SMasahiro Yamada# .gitignore and cleaning rules in the Makefile. This is the right thing 71476fee5SMasahiro Yamada# to do. However, people usually do 'git pull', 'git bisect', etc. without 81476fee5SMasahiro Yamada# running 'make clean'. Then, the stale generated files are left over, often 91476fee5SMasahiro Yamada# causing build issues. 101476fee5SMasahiro Yamada# 111476fee5SMasahiro Yamada# Also, 'git status' shows such stale build artifacts as untracked files. 121476fee5SMasahiro Yamada# What is worse, some people send a wrong patch to get them back to .gitignore 131476fee5SMasahiro Yamada# without checking the commit history. 141476fee5SMasahiro Yamada# 151476fee5SMasahiro Yamada# So, when you (re)move generated files, please move the cleaning rules from 161476fee5SMasahiro Yamada# the Makefile to this script. This is run before Kbuild starts building 171476fee5SMasahiro Yamada# anything, so people will not be annoyed by such garbage files. 181476fee5SMasahiro Yamada# 191476fee5SMasahiro Yamada# This script is not intended to grow endlessly. Rather, it is a temporary scrap 201476fee5SMasahiro Yamada# yard. Stale files stay in this file for a while (for some release cycles?), 211476fee5SMasahiro Yamada# then will be really dead and removed from the code base entirely. 221476fee5SMasahiro Yamada 23ffa46bbcSMasahiro Yamada# moved to security/selinux/genheaders 24*4e9903b0SMasahiro Yamadarm -f scripts/selinux/genheaders/genheaders 25*4e9903b0SMasahiro Yamada 26rm -f *.spec 27 28rm -f lib/test_fortify.log 29