What's new

Compiling firmware from sources

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Kobold

Regular Contributor
Good day, commander!
RMerlin, first, when I tried to compile the firmware for RT-AC66U from your sources I was unable to do that :(
But later I found what was preventing the compilation and made some modification to the folder structure of the sources. I also updated zlib to the latest 1.27, openssl to 1.0.1e, openvpn, and lzma code.

I wonder if you could be so kind to give a glance at these modified sources and issue your verdict :)
If you don't mind to do so, I'll send you a private message about it.
 
Last edited:
Good day, commander!
RMerlin, first, when I tried to compile the firmware for RT-AC66U from your sources I was unable to do that :(
But later I found what was preventing the compilation and made some modification to the folder structure of the sources. I also updated zlib to the latest 1.27, openssl to 1.0.1e, openvpn, and lzma code.

I wonder if you could be so kind to give a glance at this modified sources and issue your verdict :)
If you don't mind to do so, I'll send you a private message about it.

Hi,

I don't want to update openssl to 1.0.1 because it might break AiCloud.

I haven't updated OpenVPN yet because there's been some issues reported with it when Tomato did the update to 2.3.1.
 
I encounter a link error when trying to compile new sources built on 354.
src/router/e2fsprogs/lib/uuid : undefined reference to __tls_get_addr
:(
 
What OS? Did you install all the required packages listed in README.txt?
 
Looks like a regression caused by the toolchain update - a fresh clone fails to build. I'll take a look at it later, Tomato's Git repo is currently down.
 
Last edited:
As I can guess, you've already been able to reproduce the problem :) However, here're answers to your questions:
1. Ubuntu 13.04
2. I believe I did.
3. Previous sources (prior to 354) that lack e2fsprogs were able to be compiled.
 
Yes, it's already been fixed. Update your local repo, remove the e2fsprogs directory and checkout a fresh copy of that directory.

The issue was caused by the toolchain update to Tomato's, which enabled tls support without fully supporting it. I've reverted back to Asus's toolchain for now.
 
BTW if any developer is feeling adventurous, there's a 364 branch now on Github. All the proprietary binary blobs are still those from 354 however.
 
I'm compiling the firmware for some time with only this patch applyed and was all ok but starting from 3.0.0.4.354.27-BETA1 - 3.0.0.4.354.27 Beta1 if I remember right, I get incomplete webpage on router ui, tried with all possible browsers, reset settings to default... fresh ubuntu 12.10, 12.10 x64 and 13.04.
If I flash any of your build is ok, dunno what to do anymore...

33lnn9f.png

eb32j4.png
 
I know it's not the first time you have that issue, but I have never been able to reproduce it here, no matter what I tried. Haven't had that reported by any other developer either...

All I can suggest is to check in your browser console to see which page generated the 404, and make sure that page exists in the /www directory, and is readable by the admin user.

You do use a Linux filesystem for your local git repo, correct? Also make sure you don't have an old custom script mounting a different webui directory on top of /www (leftover from previous development for example).
 
The 404 Not Found is QIS_wizard.htm and is located in www folder
Code:
admin@RT-AC66U:/# ls -la www
...................
-rw-r--r--    1 admin    root         38313 May  1 09:45 ParentalControl.asp
-rw-r--r--    1 admin    root          2663 May  1 09:45 ParentalControl.css
-rw-r--r--    1 admin    root          6341 May  1 09:45 PrinterServer.asp
-rw-r--r--    1 admin    root         18592 May  1 09:45 QIS_wizard.htm
-rw-r--r--    1 admin    root         15972 May  1 09:45 QIS_wizard_m.htm
-rw-r--r--    1 admin    root         14113 May  1 09:45 QoS_EZQoS.asp
...................
The disk is ext4 formatted by default with ubuntu installation and I don't have another script mounting a different webui directory on top of /www because is a fresh linux installation.
This are the steps for a fresh compilation:
su
rm -r asuswrt-merlin
git clone https://github.com/RMerl/asuswrt-merlin.git
sudo ln -s /home/router/asuswrt-merlin/tools/brcm /opt/brcm
export PATH=$PATH:/opt/brcm/hndtools-mipsel-linux/bin:/opt/brcm/hndtools-mipsel-uclibc/bin
sudo mkdir -p /media/ASUSWRT/
sudo ln -s /home/router/asuswrt-merlin /media/ASUSWRT/asuswrt-merlin
cd /home/router/asuswrt-merlin/release/src-rt-6.x/router/minidlna
patch -p1 < /home/router/Downloads/samsungES.patch
cd /home/router/asuswrt-merlin/release/src-rt-6.x
make clean
make rt-ac66u
Maybe someone see something wrong in there.
Same result even if I don't apply samsungES.patch.
I have this packages loaded:
autopoint autogen autoconf automake bash bison bzip2 diffutils file flex m4 \
g++ gawk groff-base libncurses-dev libtool libslang2 make patch perl sed pkg-config \
shtool subversion tar texinfo zlib1g zlib1g-dev git-core gettext libexpat1-dev \
libssl-dev cvs gperf unzip python libxml-parser-perl gcc-multilib gconf-editor \
libxml2-dev g++-4.4 g++-multilib gitk libncurses5 libncurses5-dev libstdc++6-4.4-dev
THX
 
I have to tell you TeHashX, without your wiki post I wouldnt be where I am now compiling the source, so anything I can do to help.. :)

My build process is exactly the same as yours (except today I started pulling the 364 branch) with the exception of the patches. I originally was going to suggest removing the patch, but I see you have tried that (as well as different browsers)

I have managed to get the 404 - artifically though.

When you click on the QIS normally , the actual URL it passes (and works) is

http://<ipaddress>/QIS_wizard.htm?flag=detect

but if I type

http://<ipaddress>/QIS_wizard.htm

then I get the 404.


Its almost as if you have javascript disabled, are going through a proxy or URL filter that is stripping out the JS/context.

Obviously Javascript itself cant be completely disabled because you can't open the basic admin page (it gives you a warning and tells you to enable javascript), but I wonder if there is some URL level control taking effect here.

UPDATE: Can you enter http://<ipaddress>/QIS_wizard.htm?flag=detect directly in the browser, that would be an easy way to check..
 
Last edited:
Check your web browser console to see exactly which file is generating the 404. It's possible that the QIS page is actually trying to load another file, and it's that file that it fails to load.
 
Hi Merlin - the fact that his side main navigation panel is also missing (original picture before the 404 QIS error) makes me think its a local Javascript issue rather than the httpd.

If the browser is allowing javascript for http://IPaddress *only* , then all of the sub context menus and pages would fail (I'm speculating here, but its the only way I've been able to get similar results)
 
Last edited:
Hi Merlin - the fact that his side main navigation panel is also missing (original picture before the 404 QIS error) makes me think its a local Javascript issue rather than the httpd.

If the browser is allowing javascript for http://IPaddress *only* , then all of the sub context menus and pages would fail (I'm speculating here, but its the only way I've been able to get similar results)

That's a possibility indeed. Could also be two separate ssues. The most common cause of the side menu failing to load is a Javascript error caused by an invalid nvram value. Those errors can also be diagnosed through the browser's console.

But it's also possible that there is some security solution at work here, either from a browser plugin or an antivirus/antimalware software filtering things.
 
Those errors can also be diagnosed through the browser's console.
How?

But it's also possible that there is some security solution at work here, either from a browser plugin or an antivirus/antimalware software filtering things.
I don't think is antivirus issue because I tried on win8, win7, and 3 version of ubuntu + IE, Chrome and Firefox.
 
How?


I don't think is antivirus issue because I tried on win8, win7, and 3 version of ubuntu + IE, Chrome and Firefox.

In Chrome: Press F12, and go to the Console tab.

In Firefox: Ctrl-Shift-K

In IE: I don't remember, might be F12 too possibly?

Open the error console before reloading the page.
 
I finally managed to find the problem with chrome console
Uncaught ReferenceError: BETA1 is not defined
show_top_status
show_banner
show_menu
initial
onload
I added BETA1-thx to SerialNo= in version.config
From now I will replace (Merlin build) with (thx build) and should be ok.
Thanks again
 

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top