This is about common practices. I have a git repository containing the linux kernel. Now I want to build this linux kernel. Should I copy the sources outside the git repository and then build the kernel ? Or, should I run the build inside the git repository itself? My concern is about the many files that are created during a build process that should, I think, be not included in the git repository.
1 Answer
It's okay to compile in the repository itself. New files are ignored by Git until you add them manually for the first time. (You can use make mrproper
or git clean -dfx
to get rid of compilation output.)
-
can't I do a make clean ? is that the same as make mrproper ?– AnkurVjCommented Aug 26, 2011 at 8:28
-
1@AnkurVj:
make clean
usually cleans just the compilation output (object files).make distclean
removes everything that shouldn't be included in published tarballs of the source code.make mrproper
is specific to Linux source and is something in-between: more aggressive thanmake clean
but less so thanmake distclean
. See Makefile lines 1148 and below. Commented Aug 26, 2011 at 8:43