Which ToolChains/gcc-compilers are available for targeting the Vera 3 Plus?

Hi!

I search the forum, but didn’t manage to find an answer, so I post my question here and hope for anyone out there knowing the answer :slight_smile:

Q: What toolchains/gcc-compilers are available when compiling c-programs for the Vera 3 Plus platform?

Looking in /etc/ i can see the following system-info:

cat /etc/openwrt_build
240

cat /etc/openwrt_release
DISTRIB_ID=“OpenWrt”
DISTRIB_RELEASE=“Barrier Breaker”
DISTRIB_REVISION=“unknown”
DISTRIB_CODENAME=“mios_g450”
DISTRIB_TARGET=“ramips/generic”
DISTRIB_DESCRIPTION=“OpenWrt mios_g450 14.07”
DISTRIB_TAINTS=“no-all busybox”

cat /etc/openwrt_version
14.07

cat /mios/etc/cmh/version
1.7.4970

(which is a.k.a. Version 7.0.31 as I understand)

I have the same question in order to build my luacoap library for Vera.
As far as I know, nothing is available.

Based on similar information you found, I started to setup a toolchain using GitHub - openwrt/archive: Historical pre-merge OpenWrt archive, commit aba884cec150a9f4d1de6974a96ff90dff900f79, with a cherrypick of a more recent OpenSSL version. This code base requires a number of patches to be able to build the OpenWRT toolchain with a more recent gcc compiler than the one of 7 years ago.

The resulting toolchain can be used to build binaries for Vera. My library produces segfaults, probably because of mismatches between shared libraries available on Vera and those available in the toolchain. I was however able to build and successfully run utilities like ld, nm, objdump and gdb.

If anyone is interested, I can share some details.

2 Likes

I would be interested in any details you are willing to share :slight_smile:

I shared my current status at GitHub - vwout/vera-toolchain: Unofficial, experimental toolchain for Vera Plus home automation gateways.
Have a look at the readme for details (that I could duplicate here, but rather keep things at one location).

/ot: Maybe the better location for this topic is Developer’s Corner / General Dev Discussions. Ok if I move it?

Great write-up! I’ll be digging into the details tonight :slight_smile:

Yes, move the thread to its proper location!

Attempted to build the docker on an Ubuntu 20.04

git clone GitHub - vwout/vera-toolchain: Unofficial, experimental toolchain for Vera Plus home automation gateways
cd vera-toolchain
sudo docker build . -t vera-toolchain

However, at step 7 the build fails as:

—> 72a009efbfdd
Step 6/17 : COPY openwrt/.config archive/
—> ae79b9c4199a
Step 7/17 : COPY openwrt/tools archive/tools/
—> 684995d64c84
Step 8/17 : COPY openwrt/toolchain archive/toolchain/
—> 394f22a4ac5b
Step 9/17 : COPY openwrt/dl archive/dl/
COPY failed: stat /var/lib/docker/tmp/docker-builder106221683/openwrt/dl: no such file or directory

Is it something wrong with my Docker-installation (v19.03.12)? Doing an docker run -it ubuntu bash works perfectly… (Btw, do you want to have this conversation here, or as an issue on GitHub in the vera-toolchain.git repo?)

No, there is nothing wrong with your installation that causes the failure. This is my bad. The Dockerfile expects a directory openwrt/dl which does not exist (because git does not support empty directories). I added it.

Feel free to create tickets on Github for issues you find. This thread can be used as well, for improvements in the toolchain, or suggestions on how to use it.

Thanks for the fix! :slight_smile: The docker build process now continues, but ends up in another issue. I have reported it on the Github repo. Are you also experiencing the same thing on a clean checkout from the Github repo? Issues · vwout/vera-toolchain · GitHub