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