Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
KLone and OpenWRT
KLone and OpenWRT
This howto is intended for developers who want to integrate their own Klone web application into OpenWrt build environment.
All information applies to OpenWrt Kamikaze, newer version will probably work.
Download the source and unpack the archive in the root directory of the OpenWrt SDK:
$ tar zxvf klone-wrt-1.0.0.tar.gz
The archive creates the directory
package/klone that contains all KLone related files and folders.
make menuconfig and select the KLone package in the Network section.
Rebuild the firmware with
make or just KLone with
If OpenSSL is enabled Klone will try to build the HTTP/S server; in that case you need to patch
package/openssl/Makefile to be sure that
no-ripemd is NOT set in the
Copy the KLone package in
/bin/packages/klone* on your device and install it.
Now run the server running
package/klone is the glue with the buildroot environment. It contains the description of the webapp, dependencies and compilation instructions.
webapp/ folder is the filesystem that will be embedded into
kloned (the KLone daemon) and contains - in
webapp/www - all static (*.html, .gif, etc.) and dynamic (.kl1) web pages.
The configuration file is also into the embedded filesystem:
Once compiled you can override embedded configuration parameters using -f command line option.
During compilation everything found in webapp will be compiled and linked to Klone’s internal HTTP[/S] server.
You can specify compilation flags and additional libraries in the
Makefile.klone file. The variables are
WEBAPP_LDADD (for static libraries) and
WEBAPP_LDFLAGS (for shared libs).
mymisc/ directory is a preconfigured directory where you can put your custom C code. The utility library will be linked automatically to the web server so you can call any function in mymisc library from dynamic pages in
So to customize the basic web application you have to create new pages in
webapp/www/ and support code in
make klone-compile to rebuild the package.
More info on KoanLogic site: http://koanlogic.com/