OpenWrt Forum Archive

Topic: building packages (newbie question)

The content of this topic has been archived on 20 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

hi community
first of all, I used different versions of openwrt on different devices already, but used all time the precompiled firmware. now I want to make a step further to compile it by my own (the reason is that I need some additional packages for raspberry pi). I already set up the environment and checked out chaos calmer by git and it's compiling successfully.

what is the right way to build packages which aren't in the repo for chaos calmer (in my case lcd4linux)?

If I set up an additional trunk environment with all packages (lcd4linux is part of it) and compile the needed package, would they work with chaos calmer?

thanks for your tips

dddesign wrote:

what is the right way to build packages which aren't in the repo for chaos calmer (in my case lcd4linux)?

If I set up an additional trunk environment with all packages (lcd4linux is part of it) and compile the needed package, would they work with chaos calmer?

No.
You need to compile the packages using the same toolchain as the firmware itself. Otherwise you get incompatible binaries. (trunk uses kernel 4.1 or 4.4 and "musl" libc, while CC15.05 uses kernel 3.18 and "uClibc" libc.)

If you need packages from trunk, the easiest is to compile trunk firmware.
(Over 99% of time, trunk is quite stable, but every now and then something may be broken. But rarely.)

(Last edited by hnyman on 31 Mar 2016, 13:57)

thanks a lot for your fast response.

what would be the way to compile the desired package for cc? can I copy the files of the package from trunk env. to cc env. by hands and compile it there?

dddesign wrote:

what would be the way to compile the desired package for cc? can I copy the files of the package from trunk env. to cc env. by hands and compile it there?

You can try that. Most of the package Makefiles are compatible, but it is always possible that something has changed in between and the "new" Makefile from trunk does not work in CC15.05

It was working with package lcd4linux, great!

But: by default it's building lcd4linux-custom package. I see in the makefile that there is also an lcd4linux-full package. also package mpd has two version (mpd-mini and mpd-full). how do I build a specific "version" of a package?

The discussion might have continued from here.