AsusForum.NET -- WL500g

Вернуться   AsusForum.NET -- WL500g > Asus WL-700gE > WL-700g Firmware Discussion
Логин
Пароль
Регистрация FAQ Участники Поиск Свежие сообщения Пометить все разделы как прочитанные
Firmware Wizard Donate

Ответ
 
Опции темы Рейтинг: Рейтинг темы: Голосов - 3, средняя оценка - 5.00. Опции просмотра
  #1  
Старый 06-07-2006, 20:56
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
Lightbulb HOW-TO: Compile a firmware for the WL-700g from the GPL 1.0.4.2

Prerequisites
  • A computer with a running Linux Distribution with ash shell.
  • Basic knowledge of standard unix commands / usage
  • Some experience with compiling software with configure && make && make install would be an advantage
  • Non-dialup internet connection
My own setup is a Fedore Core 4 running on an Pentium 4. I am working with root acount.

Setting up the software

If it dosn't exist create the directory /opt.
# mkdir /opt < enter >

Download the Asus GPL sources for getting the Asus toolchain (we need mipsel-linux 3.0, so we are not downloading the lates firmware source) :

# cd /opt < enter >
# wget http://files.wl500g.info/asus/wl500g...1.8.1.9.tar.gz < enter >
# tar xvfz GPL_1.8.1.9.tar.gz < enter >
# cp -R /opt/broadcom/opt/brcm /opt < enter >

Change mipsel-linux to version 3.0:

# ln -sf /opt/brcm/hndtools-mipsel-linux-3.0 /opt/brcm/hndtools-mipsel-linux < enter >

Create a symbolik link from /opt/brcm/hndtools-mipsel-linux-3.2.3/mipsel-linux/sys-include to /opt/brcm/hndtools-mipsel-linux/mipsel-linux/sys-include

# ln -sf /opt/brcm/hndtools-mipsel-linux-3.2.3/mipsel-linux/sys-include /opt/brcm/hndtools-mipsel-linux/mipsel-linux/sys-include < enter >

Copy a file stdio.h from /opt/brcm/hndtools-mipsel-linux-3.2.3/lib/gcc-lib/mipsel-linux/3.2.3/include to /opt/brcm/hndtools-mipsel-linux/lib/gcc-lib/mipsel-linux/3.0/include:

# cp /opt/brcm/hndtools-mipsel-linux-3.2.3/lib/gcc-lib/mipsel-linux/3.2.3/include/stdio.h /opt/brcm/hndtools-mipsel-linux/lib/gcc-lib/mipsel-linux/3.0/include/stdio.h < enter >

Add toolchain path to your PATH:

# export PATH=$PATH:/opt/brcm/hndtools-mipsel-uclibc/bin:/opt/brcm/hndtools-mipsel-linux/bin < enter >

Set up GPL code

Go to the /root directory and download the GPL source code:

# cd /root < enter >
# wget http://files.wl500g.info/asus/wl700g...gE_1042tar.zip < enter >

Unzip GPL_WL700gE_1.0.4.2.tar.gz from GPL_WL700gE_1042tar.zip:

# unzip -u GPL_WL700gE_1042tar.zip < enter >

Extract the source:

# tar xvfz GPL_WL700gE_1.0.4.2.tar.gz < enter >

Make a change in 3 files by adding a path to executable mkcramfs (replace mkcramfs to /opt/broadcom/src/linux/linux/scripts/cramfs/mkcramfs):

/root/WL700g/nasoc/src/apps/Makefile
/root/WL700g/nasoc/src/apps/pivot_root/Makefile
/root/WL700g/nasoc/src/apps/mfgtest_root/Makefile

Compile the firmware

Go to the directory /root/WL700g/nasoc/src/apps and type:

# make rebuild

Последний раз редактировалось MoD, 07-07-2006 в 17:14.
Ответить с цитированием
  #1  
Старый 06-07-2006, 20:56
AsusForum MoD вне форума
Member
 
Регистрация: Nov 2003
Адрес: Netherlands
Сообщения: 213
  #2  
Старый 07-07-2006, 14:06
DaNawq DaNawq вне форума
Member
 
Регистрация: Jul 2006
Сообщения: 50
Nice manual, but I discovered a small mistake.

You just have to switch the parameters in your symbolic link commands.

# ln -sf /opt/brcm/hndtools-mipsel-linux-3.0 /opt/brcm/hndtools-mipsel-linux < enter >
# ln -sf /opt/brcm/hndtools-mipsel-linux-3.2.3/mipsel-linux/sys-include /opt/brcm/hndtools-mipsel-linux/mipsel-linux/sys-include < enter >

After that the firmware compiles to the following error:

Код:
make[3]: Entering directory `/root/WL700g/nasoc/src/apps/tcp_wrapper'
mipsel-linux-gcc -O -DFACILITY=LOG_MAIL  -DHOSTS_ACCESS -DPARANOID  -DGETPEERNAME_BUG -DBROKEN_FGETS -DLIBC_CALLS_STRTOK   -DDAEMON_UMASK=022 -DREAL_DAEMON_DIR=\"/usr/sbin\" Gilouche  -DSEVERITY=LOG_INFO         -DRFC931_TIMEOUT=10  -DHOSTS_DENY=\"/etc/hosts.deny\" -DHOSTS_ALLOW=\"/etc/hosts.allow\"   -DBROKEN_SO_LINGER -DSYS_ERRLIST_DEFINED  -Dvsyslog=myvsyslog -DALWAYS_HOSTNAME -c options.c
mipsel-linux-gcc: Gilouche: No such file or directory
make[3]: *** [options.o] Error 1
Hope you can help me

UPDATE: By editing the cflags in tcp_wrapper I could surround that problem, but I run into new ones :P
We'll see by when I can help you with the telnetd^^

One small question at the end:

By flashing a new firmware, do I lose all shares with all the files in them?

thx alot.

Последний раз редактировалось DaNawq, 07-07-2006 в 14:55.
Ответить с цитированием
  #3  
Старый 07-07-2006, 17:28
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
Цитата:
Nice manual, but I discovered a small mistake.

You just have to switch the parameters in your symbolic link commands.

# ln -sf /opt/brcm/hndtools-mipsel-linux-3.0 /opt/brcm/hndtools-mipsel-linux < enter >
# ln -sf /opt/brcm/hndtools-mipsel-linux-3.2.3/mipsel-linux/sys-include /opt/brcm/hndtools-mipsel-linux/mipsel-linux/sys-include < enter >

After that the firmware compiles to the following error:

Код:
make[3]: Entering directory `/root/WL700g/nasoc/src/apps/tcp_wrapper'
mipsel-linux-gcc -O -DFACILITY=LOG_MAIL  -DHOSTS_ACCESS -DPARANOID  -DGETPEERNAME_BUG -DBROKEN_FGETS -DLIBC_CALLS_STRTOK   -DDAEMON_UMASK=022 -DREAL_DAEMON_DIR=\"/usr/sbin\" Gilouche  -DSEVERITY=LOG_INFO         -DRFC931_TIMEOUT=10  -DHOSTS_DENY=\"/etc/hosts.deny\" -DHOSTS_ALLOW=\"/etc/hosts.allow\"   -DBROKEN_SO_LINGER -DSYS_ERRLIST_DEFINED  -Dvsyslog=myvsyslog -DALWAYS_HOSTNAME -c options.c
mipsel-linux-gcc: Gilouche: No such file or directory
make[3]: *** [options.o] Error 1
Hope you can help me

UPDATE: By editing the cflags in tcp_wrapper I could surround that problem, but I run into new ones :P
We'll see by when I can help you with the telnetd^^
1) I fixed symbolic link mistake in the manual. Thanks!
2) I just rebuilt the enviorment and recompiled without any problems. I dont know what is wrong.

Now I'm trying to incude telnetd.... for now it seems that make menuconfig doesnt work. makes a mistake at compilation.

Последний раз редактировалось MoD, 07-07-2006 в 18:18.
Ответить с цитированием
  #4  
Старый 07-07-2006, 19:13
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
Цитата:
By flashing a new firmware, do I lose all shares with all the files in them?
no I don't. all files stay where they are saved. no problems.

But I don't take any resposibility for your data lost
Ответить с цитированием
  #5  
Старый 07-07-2006, 19:23
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
I noticed that if you want to enable telnetd, you will need:

1) launch make menuconfig
2) load settings from file NASoC_config

My question is: do I have to select only telnetd and nothing else? like addgroup, passwd or something similar?

Give me a hint!

I enabled telnetd and added something like this to services.c:
Цитата:
int
start_telnetd(void){
int ret = 0;
pid_t pid;
char *telnetd_argv[] = { "telnetd", NULL };
ret = _eval(telnetd_argv, NULL, 0, &pid);
dprintf("done\n");
return ret;
}
and added the function to the function start_services.

reflashed the firmware, but telnetd is not working

Последний раз редактировалось MoD, 07-07-2006 в 21:00.
Ответить с цитированием
  #6  
Старый 07-07-2006, 20:14
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
After compiling the firmware I even see (in the directory /root/WL700g/nasoc/src/apps/mipsel/target/sbin) that telnetd has been compiled.

But when I flash and reboot the router, telnetd has not been started
Ответить с цитированием
  #7  
Старый 07-07-2006, 22:11
DaNawq DaNawq вне форума
Member
 
Регистрация: Jul 2006
Сообщения: 50
I do believe there's still something wrong with the firmware update itself.

When I flash my new image to the router it still keeps all my settings.

I think only by a complete update (hdd also) it will accept the new changes.

Still experimenting ;-)
Ответить с цитированием
  #8  
Старый 07-07-2006, 22:50
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
I'm thinking about two possibilities:

1) your version. try firmware restoration tool. or reset router after upgrade?!
2) old busybox that doesnt support telnetd

I changed busybox from Oleg's firmware. Trying to compile now.
Ответить с цитированием
  #9  
Старый 07-07-2006, 22:55
DaNawq DaNawq вне форума
Member
 
Регистрация: Jul 2006
Сообщения: 50
My version isn't really working yet

Perhaps I'll connect the harddrive to a normal PC to see weather there are stored some configs or not...

Последний раз редактировалось DaNawq, 07-07-2006 в 23:00.
Ответить с цитированием
  #10  
Старый 07-07-2006, 22:57
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
Цитата:
Сообщение от DaNawq
My version isn't really working yet

Perhaps I'll connect the harddrive to a normal PC to see wether there are stored some configs or not...
I changed firmware version. At least it appeared on web interface...
Ответить с цитированием
  #11  
Старый 07-07-2006, 23:14
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
I noticed that WL700gE in web pages use ash shell. Telnetd by default uses whitch one? does that makes sense?
Ответить с цитированием
  #12  
Старый 07-07-2006, 23:15
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
recompiled with busybox from Oleg's source. The result wasn't succesfull
Ответить с цитированием
  #13  
Старый 08-07-2006, 05:26
hmantsao hmantsao вне форума
Member
 
Регистрация: Jul 2006
Сообщения: 31
Отправить сообщение для  hmantsao с помощью ICQ Отправить сообщение для hmantsao с помощью MSN
telnet to 700ge

Цитата:
Сообщение от MoD
I noticed that WL700gE in web pages use ash shell. Telnetd by default uses whitch one? does that makes sense?
on the wl700ge, the telnetd is "/bin/utelnetd",you can try to start it. I had telnet to 700ge one month ago using a stupid method.

1. modify the web started page fils ( /layout/layout.cgi ) from neighbor.
2. add " /bin/utelnetd &" on the page, need carefully the add location.
3. reload the web starting page.

ps.
1.this method worked on firmware 1.0.4.1, didn't check on better or new
2.if we can write utelnetd on starting process, will easy to telnet . becase this method will been cleared whe you reboot.

you can contact with me by IM ( see the userCP).
my new firmware didn't finish , still have some problem.
Ответить с цитированием
  #14  
Старый 08-07-2006, 10:37
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
You are right! there is utelnetd in /bin directory. I'll try to use this daemon. but for this daeomn the full syntax is:

Цитата:
/bin/utelnetd -l /bin/sh -d
The question is if the parameter -l /bin/sh is important? I'll try to use /bin/utelnetd -d

Последний раз редактировалось MoD, 08-07-2006 в 10:40.
Ответить с цитированием
  #14  
Старый 08-07-2006, 10:37
AsusForum MoD вне форума
Member
 
Регистрация: Nov 2003
Адрес: Netherlands
Сообщения: 213
  #15  
Старый 08-07-2006, 10:49
MoD MoD вне форума
Senior Member
 
Регистрация: Sep 2005
Сообщения: 213
Цитата:
Сообщение от hmantsao
1. modify the web started page fils ( /layout/layout.cgi ) from neighbor.
2. add " /bin/utelnetd &" on the page, need carefully the add location.
where is that layout.cgi located? I cant find in my router
what do you mean with
Цитата:
, need carefully the add location.
Ответить с цитированием
Ответ

Опции темы
Опции просмотра Оценка этой теме
Оценка этой теме:

Ваши права в разделе
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is Вкл.
[IMG] код Вкл.
HTML код Выкл.

Быстрый переход

Похожие темы
Тема Автор Раздел Ответов Последнее сообщение
Firmware upgrading HOWTO Styno WL-500g/WL-500gx Tutorials 6 30-07-2008 21:00
twonky media server, network drive with oleg firmware black_bottom WL-HDD Q&A 3 22-03-2006 07:15
Download of current GPL source for firmware? LarsAC WL-500g Custom Development 4 26-02-2006 15:16
Custom Firmware v1.1.2.7 JOCKYW2001 WL-HDD Firmware Releases 59 11-12-2004 12:26
Flashing Oleg's Firmware in WL HDD hugo WL-HDD Q&A 29 21-10-2004 14:55


Часовой пояс GMT +1, время: 22:27.


Copyright ©2003 - 2008, van Boekel Networks
Вы оценили эту тему: