by oftenwrong · 3y ago · 0 comments
- No tracking of changes to build rules. The build rule of a target should be one of its dependencies.
- No protection from dirty builds. Your sources root is also your output root, and make does not help you keep it clean.
- No options for extending the build to use alternate up-to-date checks (e.g. not mtimes), caches, execution mechanisms, etc.
These all have workarounds, but they require the developer to manually include the workarounds in every build rule.
Only if you learnt to program by reading Microsoft examples. Unix developers do not mix compiled files with source files.
Seriously, it’s very project-dependent, but you’re lucky if your thing of choice that you need to build often supports a separate build directory, let alone enforces it.
$ cd /tmp/build
$ ../bash-5.2.15/configure
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
Beginning configuration for bash-5.2-release for x86_64-pc-linux-gnu
checking for gcc... gcc
... etc ...
$ tree
.
├── builtins
│ └── Makefile
├── config.h
├── config.log
├── config.status
├── doc
│ └── Makefile
├── examples
│ └── loadables
│ ├── Makefile
│ ├── Makefile.inc
│ ├── Makefile.sample
│ └── perl
│ └── Makefile
├── lib
│ ├── glob
│ │ └── Makefile
│ ├── intl
│ │ └── Makefile
│ ├── malloc
│ │ └── Makefile
│ ├── readline
│ │ └── Makefile
│ ├── sh
│ │ └── Makefile
│ ├── termcap
│ │ └── Makefile
│ └── tilde
│ └── Makefile
├── Makefile
├── po
│ ├── Makefile
│ ├── Makefile.in
│ └── POTFILES
├── stamp-h
├── support
│ ├── bashbug.sh
│ ├── bash.pc
│ └── Makefile
└── tests
17 directories, 24 files
The makefiles and any files they generate are in /tmp/build, the source directory remains unmodified.(Recursive make, eww!) ;)