blob: 65dbf2e7ace9735f7f24763490c80d1bd6235d76 [file] [log] [blame]
Neels Hofmeyrfeeedad2017-08-23 00:13:33 +02001=== gen_makefile.py
2
Neels Hofmeyr0a1bdff2017-08-13 03:22:42 +02003This provides a set of top-level makefiles to build variants of the Osmocom
4source trees. It is inteded for the core network components and related
5projects, but works generically.
6
7The idea is to have all your Osmocom git clones in ./src, while keeping one or
8more separate build trees in ./make-*.
9
10Run ./gen_makefile.py with a choice of projects (2G only or also 3G?)
Neels Hofmeyrd3707d02017-09-03 23:57:55 +020011and a choice of configure options.
Neels Hofmeyr0a1bdff2017-08-13 03:22:42 +020012
Neels Hofmeyrd3707d02017-09-03 23:57:55 +020013Examples:
14
15Full 2G and 3G support:
16
17 ./gen_makefile.py 3G+2G.deps default.opts
18
192G only (requires to pass no-iu.opts), and a custom dir name of 'make-2G':
20
21 ./gen_makefile.py 2G.deps default.opts no-iu.opts -m make-2G
Neels Hofmeyr0a1bdff2017-08-13 03:22:42 +020022
23This generates a new dir containing a Makefile. When you run make in it, this
24will clone the source trees (if not present yet) and build all of them in the
25right order:
26
Neels Hofmeyrd3707d02017-09-03 23:57:55 +020027 cd make-3G+2G-default
Neels Hofmeyr0a1bdff2017-08-13 03:22:42 +020028 make
29
30If you make modifications in one of the source trees, this Makefile will pick
31it up, rebuild the project and also rebuild all dependencies (according to the
32*.deps file the Makefile was generated from).
33
34If you modify the *.deps or *.opts file, you can easily run 'make regen' in a
35make-* subdir to regenerate the Makefile from the same files.
36
37In your make-* subdir there are empty status files that are touched for every
38completed make target. From these, 'make' can detect what needs to be rebuilt.
39You can manually remove them to force a rebuild of a specific target.
40
41For example, if you 'rm .make.libosmocore.autoconf', libosmocore and all
42projects depending on libosmocore will be rebuilt from scratch.
43
44For more details on the *.opts and *.deps syntax, read the docs at the top of
45./gen_makefile.py.
46
47It is also easily possible to keep sources and build trees in various
48configurations, see the command line options of ./gen_makefile.py.
Neels Hofmeyrfeeedad2017-08-23 00:13:33 +020049
50
51=== osmo-uninstall.sh
52
53Remove osmocom built binaries and headers from given prefix,
54default is /usr/local.
Neels Hofmeyrf6402d82017-09-04 04:32:21 +020055
56
57=== src/*
58
59Find other useful scripts in src/, see src/README.