diff options
author | Simon Hoinkis <simon.hoinkis@codethink.co.uk> | 2015-03-19 14:50:08 +0000 |
---|---|---|
committer | Richard Dale <richard.dale@codethink.co.uk> | 2015-05-19 16:56:06 +0100 |
commit | bb14cfdb9d2358ec663926f080118685c629bef7 (patch) | |
tree | 894ac63beda64ccf9d66d5f1e61792cc5d430f45 /strata/cpe-wrt | |
parent | d2501ac90d1841ab85f57ef58790d2328253fe41 (diff) | |
download | definitions-bb14cfdb9d2358ec663926f080118685c629bef7.tar.gz |
Update various OpenWrt packages
* OpenWrt (base-files): Search and replace 'export -n' with 'export'
in lib/functions/preinit.sh
* procd: Install the binaries in /sbin
* fstools: Install the binaries in /sbin
* uci, ubox, ubus, firewall3: Create the correct symlinks in /bin
* Busybox: Change to a repository which includes OpenWrt patches
and delete the false sed command
TODO:
* Complete the adding of iwinfo for rpcd
* Busybox build
Diffstat (limited to 'strata/cpe-wrt')
-rw-r--r-- | strata/cpe-wrt/base-files.morph | 17 | ||||
-rw-r--r-- | strata/cpe-wrt/firewall3.morph | 15 | ||||
-rw-r--r-- | strata/cpe-wrt/fstools.morph | 7 | ||||
-rw-r--r-- | strata/cpe-wrt/iwinfo.morph | 8 | ||||
-rw-r--r-- | strata/cpe-wrt/netifd.morph | 12 | ||||
-rw-r--r-- | strata/cpe-wrt/rpcd.morph | 7 | ||||
-rw-r--r-- | strata/cpe-wrt/ubox.morph | 15 | ||||
-rw-r--r-- | strata/cpe-wrt/ubus.morph | 13 | ||||
-rw-r--r-- | strata/cpe-wrt/uci.morph | 12 |
9 files changed, 94 insertions, 12 deletions
diff --git a/strata/cpe-wrt/base-files.morph b/strata/cpe-wrt/base-files.morph index b4ec3bb2..50ac95b8 100644 --- a/strata/cpe-wrt/base-files.morph +++ b/strata/cpe-wrt/base-files.morph @@ -1,11 +1,10 @@ name: base-files kind: chunk -#build-commands: -#- | -# export TOPDIR="../.." -# export INCLUDE_DIR="TOPDIR/include" -# cd package/base-files && make +# "export -n" is not supported + +pre-configure-commands: +- sed -i "s/export -n/export/" package/base-files/files/lib/functions/preinit.sh install-commands: # FHS directories @@ -18,17 +17,17 @@ install-commands: - install package/system/procd/files/reload_config "$DESTDIR"/sbin/ - install package/system/procd/files/procd.sh "$DESTDIR"/lib/functions/ -#netifd +# netifd - | cp -r package/network/config/netifd/files/* "$DESTDIR"/ -#ubox +# ubox - | cp -r package/system/ubox/files/* "$DESTDIR"/etc/init.d/log -#ubox +# uci - | cp -r package/system/uci/files/* "$DESTDIR"/ -#lock symlink +# lock symlink - ln -s busybox "$DESTDIR"/bin/lock diff --git a/strata/cpe-wrt/firewall3.morph b/strata/cpe-wrt/firewall3.morph new file mode 100644 index 00000000..0ef34b5a --- /dev/null +++ b/strata/cpe-wrt/firewall3.morph @@ -0,0 +1,15 @@ +name: ubox +kind: chunk + +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=$PREFIX +- make + +install-commands: +- make install + +post-install-commands: +- | + install -d "$DESTDIR/sbin" + cd "$DESTDIR/sbin" + ln -s ../usr/sbin/fw3 firewall3 diff --git a/strata/cpe-wrt/fstools.morph b/strata/cpe-wrt/fstools.morph index cf5a730a..0a455968 100644 --- a/strata/cpe-wrt/fstools.morph +++ b/strata/cpe-wrt/fstools.morph @@ -3,3 +3,10 @@ kind: chunk pre-configure-commands: - sed -i "s/-Werror//" CMakeLists.txt + +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=/ +- make + +install-commands: +- make install diff --git a/strata/cpe-wrt/iwinfo.morph b/strata/cpe-wrt/iwinfo.morph new file mode 100644 index 00000000..5040f3a5 --- /dev/null +++ b/strata/cpe-wrt/iwinfo.morph @@ -0,0 +1,8 @@ +name: iwinfo +kind: chunk + +build-commands: +- make + +install-commands: +- make install diff --git a/strata/cpe-wrt/netifd.morph b/strata/cpe-wrt/netifd.morph index 0d8c835c..20126327 100644 --- a/strata/cpe-wrt/netifd.morph +++ b/strata/cpe-wrt/netifd.morph @@ -4,5 +4,13 @@ kind: chunk pre-configure-commands: - sed -i "s/-Werror//" CMakeLists.txt - sed -i "s/netifd\s\${LIBS}/netifd \${LIBS} \${LIBNL_LIBRARIES} \${JSONC_LIBARIES}/" CMakeLists.txt -- sed -i "s/#include\s\"config.h\"/#include \"config.h\"\n#include \"bits.h\"/" handler.h -- sed -i "s/SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS \"\")/SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS \"\")\nINCLUDE(FindPkgConfig)\nPKG_CHECK_MODULES(JSONC json-c)\nIF(JSONC_FOUND)\n ADD_DEFINITIONS(-DJSONC)\n INCLUDE_DIRECTORIES(${JSONC_INCLUDE_DIRS})\nENDIF()\n\nPKG_CHECK_MODULES(LIBNL libnl-3.0)\nINCLUDE_DIRECTORIES(${LIBNL_INCLUDE_DIRS})\n/" CMakeLists.txt +- sed -i "s/#include\s\"config.h\"/#include \"config.h\"\n#include \"json-c\/bits.h\"/" handler.h +- sed -i "s/#include <json/#include <json-c/" handler.c handler.h +- sed -i "s/SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS \"\")/SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS \"\")\nINCLUDE(FindPkgConfig)\nPKG_CHECK_MODULES(JSONC json-c)\nIF(JSONC_FOUND)\n ADD_DEFINITIONS(-DJSONC)\n INCLUDE_DIRECTORIES(${JSONC_INCLUDE_DIRS})\nENDIF()\n\nPKG_CHECK_MODULES(LIBNL libnl-3.0)\nINCLUDE_DIRECTORIES(\${LIBNL_INCLUDE_DIRS})\n/" CMakeLists.txt + +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=$PREFIX +- make VERBOSE=1 + +install-commands: +- make install diff --git a/strata/cpe-wrt/rpcd.morph b/strata/cpe-wrt/rpcd.morph index 85ca41a1..ae62a71a 100644 --- a/strata/cpe-wrt/rpcd.morph +++ b/strata/cpe-wrt/rpcd.morph @@ -3,3 +3,10 @@ kind: chunk pre-configure-commands: - sed -i "s/json\/json.h/json-c\/json.h/" include/rpcd/plugin.h + +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=$PREFIX +- make + +install-commands: +- make install diff --git a/strata/cpe-wrt/ubox.morph b/strata/cpe-wrt/ubox.morph index 2280a207..3281f166 100644 --- a/strata/cpe-wrt/ubox.morph +++ b/strata/cpe-wrt/ubox.morph @@ -1,5 +1,18 @@ name: ubox kind: chunk +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=$PREFIX +- make + install-commands: -- make DESTDIR="$DESTDIR" install +- make install + +post-install-commands: +- | + install -d "$DESTDIR/sbin" + cd "$DESTDIR/sbin" + ln -s ../usr/sbin/kmodloader kmodloader + ln -s ../usr/sbin/lsbloader lsbloader + ln -s ../usr/sbin/validate_data validate_data + ln -s ../usr/sbin/logd logd diff --git a/strata/cpe-wrt/ubus.morph b/strata/cpe-wrt/ubus.morph index 245a51b6..d5ed234a 100644 --- a/strata/cpe-wrt/ubus.morph +++ b/strata/cpe-wrt/ubus.morph @@ -1,5 +1,18 @@ name: ubus kind: chunk +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=$PREFIX +- make + install-commands: - make install + +post-install-commands: +- | + install -d "$DESTDIR/sbin" + cd "$DESTDIR/sbin" + ln -s ../usr/sbin/ubusd ubusd + install -d "$DESTDIR/bin" + cd "$DESTDIR/bin" + ln -s ../usr/bin/ubus ubus diff --git a/strata/cpe-wrt/uci.morph b/strata/cpe-wrt/uci.morph new file mode 100644 index 00000000..d5734208 --- /dev/null +++ b/strata/cpe-wrt/uci.morph @@ -0,0 +1,12 @@ +name: uci +kind: chunk + +build-commands: +- cmake -DCMAKE_INSTALL_PREFIX=$PREFIX +- make + +install-commands: +- make install + +post-install-commands: +- install -d "$DESTDIR/bin" && cd "$DESTDIR/bin" && ln -s ../usr/bin/uci uci |