How to install/port projects from Github on Turris?

Hi All
I’m new to Turris/OpenWrt. I want to know a basic concept that how to install/port projects from gibhub on turris os? For example, I want to run mitmproxy on turris.
Here are I’m trying

  1. pip install mitmproxy - ccache_cc error (caused by brotlipy package)
  2. download mitmproxy from Github and run “python install” - ccache_cc error (caused by brotlipy package)
    if I try to build brotlipy package, it doesn’t support gcc, make on turris.
    So, I think maybe I need do it on linux(ex: Ubunto), but I don’t know what is basic develop flow and how to integrate mitmproxy project into turris. Does anyone can give a tip ? any tip or reference article are welcome. thanks


opkg update
opkg install mitmproxy

It should install it or it will say this:
Package mitmproxy (0.4.1-4) installed in root is up to date.

List of all precomiled packages on Omnia (which you can install with opkg install):

you might be better off starting up a lxc container with ubuntu in it, then installing/building software into there. plus it keeps the omnia clean.

if there is a native package (System->Software->Available packages) then you might want to try them as well, but they might not be as up-to-date as what you can install yourself from git or a ppa.

Hi Pepe
Thanks, I already tested it, but I got eror about pyOpenSSL version is out of date when I run “mitmproxy_ssl”. Thus, I reinstall new version of pyOpenSSL, then it causes compile error from it’s dependent packages, ex: cffi
Besides, I think I also need to create valid certificates next.

/usr/lib/python2.7/site-packages/twisted/internet/ UserWarning: Your version of pyOpenSSL, 0.10, is out of date.
Please upgrade to at least 0.12 and install service_identity from
Without the service_identity module and a recent enough pyOpenSSL tosupport it, Twisted can perform only rudimentary TLS client hostnameverification.
Many valid certificate/hostname mappings may be rejected.
verifyHostname, VerificationError = _selectVerifyImplementation()
Please do create server certificates (see readme).

Hi scottjl
Thanks your information.
(a) I also try to build turros-os under lxc container. Although I got build error, I will try my best to fix it.
if I pass the turris-os system build (from, how to plus project into turris os ? Could you give more tips, thanks
(b) Yes, I already re-install some old native packages, some of them are fine to re-install, however, some of them need tools to finish install such as make, c compile, etc. that’s why I think I need do it on linux.

Sorry. I think you misunderstood. I meant set up a Ubuntu LXC container and install software into that OS, not to rebuild Turris-OS/OpenWRT in Ubuntu.

Inside the Ubuntu container run mitmproxy, or transmission or apache or anything you want inside there. Run as little as possible on the Turris-OS/OpenWRT directly.

Ubuntu has great support for 3rd party software, OpenWRT has support for some software and it is kept somewhat up-to-date.

Hi scottjl
thanks your explain. mitmproxy runs well on Ubuntu and my goal is run it on turris/openwrt. That’s why I create this post.

But scottjl’s idea is that you should not attempt to run it on OpenWRT. (There are not many precompiled packages, and the software you install outside of these packages won’t benefit of the Turris’ great strength, auto-update.)

I think that scottjl wanted you to give in and to run mitmproxy on a Debian or ArchLinux or Ubuntu LXC container, running on the Turris.

it wasn’t a matter of “giving in” just the recommendation to leave OpenWRT as clean as possible and run non-essential software in a LXC container. this has the benefit of less chance of corruption to OpenWRT, and a slightly smaller security risk running 3rd party software in LXC containers vs. directly in OpenWRT. it’s also generally easier to build and install other packages in a full linux environment than the limited OpenWRT environment. i’ve been using Linux for 20 years and OpenWRT for over a decade, so I have some experience with the environments. :slight_smile:

Thanks your reminding. Because this is a experimental project, we don’t care about performance issue.
We just want to know the correct steps to do that.
So if I still want to port project (form Github and not be included in openWrt packages) to turris os.
I think we need to follow cross compile flow (, What do you think about that?

I think it is a good place to start. I’m not sure what additional steps may be needed to compile specifically for the Omnia. As long as the software you’re trying to use isn’t interacting with the hardware directly, it should be relatively easy to port over with minimal changes. The closer you get to the hardware the more work you’re going to have to do on your own. I wish you the best of luck on your endeavors. Please share your successes and failures on the forums so that others may learn from you.

Hi scottjl
I try to build it under different environments, but it alwasy gets compile error on base-files package, please refer to
So, could you tell me which linux version is fine to build turris os? or how to fix this issue. Thanks very much.

Sorry, I can’t tell you how to build TurrisOS, as others have reported in other threads, there are difficulties building TurrisOS. My suggestion to you was to build your software packages in a more standard environment running in a LXC container. Such as setting up a Ubuntu container and building mitmproxy within that.