diff options
author | P. J. McDermott <pjm@nac.net> | 2014-03-11 21:16:57 (EDT) |
---|---|---|
committer | P. J. McDermott <pjm@nac.net> | 2014-03-11 21:16:57 (EDT) |
commit | d88085a2a474026282e462a72fcc8b1780b0af73 (patch) | |
tree | 98ce48a90b8e5f5cdcd07d8818d546c1399b97af /build | |
parent | 0a325d164bccd3bdbe7c6dc6a5f30cdc23837878 (diff) |
build: Detect plat, pkgs, and vers automatically.
Diffstat (limited to 'build')
-rwxr-xr-x | build | 24 |
1 files changed, 12 insertions, 12 deletions
@@ -1,16 +1,8 @@ #!/usr/bin/make -f -# Host/target platform: -plat = dev - -# The OPK_SOURCE_VERSION_UPSTREAMs of packages: -busybox_ver = 1.21.1 - -# Nothing beyond this point requires updating for platform porting or new -# upstream package versions. - -base = /usr/share/platconf/$(plat) -busybox_platconf = config-busybox-$(plat).data/$(base)/busybox_$(busybox_ver) +plat = $${OPK_SOURCE\#config-} +config_pkg = config-$${pkg}-$(plat) +platconf_dir = $(config_pkg).data/usr/share/platconf/$(plat)/$${pkg}_$${ver} nop: @: @@ -19,4 +11,12 @@ build: @: install: build - install -D src/busybox/config $(busybox_platconf)/busybox.config + set -e; \ + for pkg in src/*; do \ + pkg="$${pkg#src/}"; \ + for ver in "src/$${pkg}/"*; do \ + ver="$${ver#src/$${pkg}/}"; \ + mkdir -p "$(platconf_dir)"; \ + cp -p "src/$${pkg}/$${ver}/"* "$(platconf_dir)"; \ + done; \ + done |