Topic: TP-Link WR-1043ND and compiling OpenWRT

Hello all!
My question about modding firmware. I need PPTP VPN-client (ISP require VPN for access to the Internet), VPN-server (sometime I need access  to my computer from another places), print server - its necessary. If possible, I'll want to add Samba, NTFS-support and torrent-client.
So, what I'm doing:

1. Install 32-bit Ubuntu 10.10, activate root account and change user to root
2. Install necessary packages

apt-get install build-essential asciidoc autoconf binutils bison bzip2 \
  flex gawk gettext libncurses5-dev libz-dev patch unzip zlib1g-dev

3. Install SVN 

apt-get install subversion

4. Get src-codes

mkdir /111
cd /111
svn co svn://svn.openwrt.org/openwrt/branches/backfire

5. Get possibility for compiling under root - go to /111/backfire/include/prereq-build.mk file, commenting line

define Require/non-root
    #[ "$$(shell whoami)" != "root" ]

and save the changes
6. Check packages for firmware compiling

make defconfig

Everything is OK now
7. Update and install firmware packages

svn up
./scripts/feeds update -a
./scripts/feeds install -a

8. Run firmware configurator and configure it

make menuconfig

9. Run firmware creating process

make V=99

After a few hours waiting, I got fail - in /111/backfire/bin/ar71xx directory i can see a lot of ready packages, but that's all sad
No firmware image, last lines in terminal is

./libtool: 323: s,^.*/,,g: not found
./libtool: 323: s,^.*/,,g: not found
./libtool: 859: -e: not found
*** Warning: inferring the mode of operation is deprecated.
*** Future versions of Libtool will require --mode=MODE be specified.
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
./libtool: 6991: -e: not found
: compile: cannot determine name of library object from `'
make[6]: *** [popt.lo] Error 1
make[6]: Leaving directory `/111/backfire/build_dir/target-mips_r2_uClibc-0.9.30.1/popt-1.7'
make[5]: *** [all-recursive] Error 1
make[5]: Leaving directory `/111/backfire/build_dir/target-mips_r2_uClibc-0.9.30.1/popt-1.7'
make[4]: *** [all] Error 2
make[4]: Leaving directory `/111/backfire/build_dir/target-mips_r2_uClibc-0.9.30.1/popt-1.7'
make[3]: *** [/111/backfire/build_dir/target-mips_r2_uClibc-0.9.30.1/popt-1.7/.built] Error 2
make[3]: Leaving directory `/111/backfire/feeds/packages/libs/popt'
make[2]: *** [package/feeds/packages/popt/compile] Error 2
make[2]: Leaving directory `/111/backfire'
make[1]: *** [/111/backfire/staging_dir/target-mips_r2_uClibc-0.9.30.1/stamp/.package_compile] Error 2
make[1]: Leaving directory `/111/backfire'
make: *** [world] Error 2

Whats wrong?

P.S. Sorry for my English, it's not mother tongue for me and I newbie in Linux... Show the manual if its possible... Thanks for any advices!
P.P.S. I tried to find solution in forum search and in Google. Without any result sad

2 (edited by written_direcon 2011-02-22 14:19:09)

Re: TP-Link WR-1043ND and compiling OpenWRT

You should not build in the root account. Build as normal user.

Re: TP-Link WR-1043ND and compiling OpenWRT

I'm getting the same errors while trying to compile asterisk 1.6.x for BCM63XX platform. I'm not compiling as root.

Re: TP-Link WR-1043ND and compiling OpenWRT

Thanks for your attempt to help, I tried to construct firmware as usually user. Fail.
Same errors sad

Re: TP-Link WR-1043ND and compiling OpenWRT

balbesenok wrote:

7. Update and install firmware packages

svn up
./scripts/feeds update -a
./scripts/feeds install -a

Whats wrong?

You really don't need to compile all packages, install only the packages you need.
For the case, remove the offending package:

./scripts/feeds uninstall popt

Also locate and remove the packages that depend on popt.

8 bis) If you insist check with prereq if need another round of apt-get install, then ignore those nasty errors you can't fix:

make menuconfig
make prereq
make V=99 IGNORE_ERRORS=m

But, there is always a but, make first a bare menuconfig default, on success you can safely ignore the errors. Uploading a image with compile errors makes me sweat.

Netgear WNR854T (ARM Marvell Orion CPU 500MHz, Marvell 88W8361P mini-PCI STA only, 8/32MB) - trunk r17427 since 09/09/09 to 06-06-12 GLOD
TP-LINK TL-WR741ND v1.9 (Atheros AR7240 CPU 350MHz, Atheros AR9285 Chipset, 4/32MB) - trunk r23281 since 10/10/10
TP-LINK TL-MR3420 v1.1, TL-MR3220 v1.2 - trunk r25302 since 11/11/11
TP-LINK TL-WR842ND v1.0, TL-WR1043ND v1.8 - 12.09-rc1 since 12/12/12

Re: TP-Link WR-1043ND and compiling OpenWRT

Nilfred wrote:
balbesenok wrote:

7. Update and install firmware packages

svn up
./scripts/feeds update -a
./scripts/feeds install -a

Whats wrong?

You really don't need to compile all packages, install only the packages you need.
For the case, remove the offending package:

./scripts/feeds uninstall popt

Also locate and remove the packages that depend on popt.

8 bis) If you insist check with prereq if need another round of apt-get install, then ignore those nasty errors you can't fix:

make menuconfig
make prereq
make V=99 IGNORE_ERRORS=m

But, there is always a but, make first a bare menuconfig default, on success you can safely ignore the errors. Uploading a image with compile errors makes me sweat.

I want to compile only chan_datacard package ... and this package uses popt
Any other solution?

Re: TP-Link WR-1043ND and compiling OpenWRT

Try trunk?

BTW: What CPU do you have and how long does make need?

8 (edited by fpaliuc 2011-02-23 13:07:45)

Re: TP-Link WR-1043ND and compiling OpenWRT

Orca wrote:

Try trunk?

BTW: What CPU do you have and how long does make need?

The trunk version is 25666. I only need the chan_datacard package. It seems that it's the popt package that gives error when compiling. (popt-1.7).

I've tried already on 2 PC's: one Core Duo 1.73 Ghz and the other - Dual Core 2 Ghz
Anything we can do to fix the popt-1.7 package compiling?

9 (edited by written_direcon 2011-02-24 19:56:01)

Re: TP-Link WR-1043ND and compiling OpenWRT

To build Backfire branch (with LuCI web GUI included) for the TP-Link WR1043ND v1 you have to do:

cd ~
svn checkout svn://svn.openwrt.org/openwrt/branches/backfire ~/wr1043nd
cd ~/wr1043nd
./scripts/feeds update packages luci
./scripts/feeds install -a -p luci
make menuconfig

In menuconfig select:
Target System: Atheros AR71xx/AR7240/AR913x
Target Profile: TP-LINK TL-WR1043ND v1
LuCI / Collections / luci: y
Kernel modules / USB Support / kmod-usb-kore: y
Kernel modules / USB Support / kmod-usb-ohci: y
Kernel modules / USB Support / kmod-usb-storage: y
Kernel modules / USB Support / kmod-usb-uhci: y

make

This works for me building Backfire under Ubuntu 10.10 Server Edition (32bit) in VMware Server.

Re: TP-Link WR-1043ND and compiling OpenWRT

Thanks for all and Great Thanks for  written_direcon )))

I tried to compile firmware as he said and it works )))

Re: TP-Link WR-1043ND and compiling OpenWRT

mine is here

https://github.com/axet/openwrt-dir300-b1