OpenWrt Forum Archive

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

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

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

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

(Last edited by written_direcon on 22 Feb 2011, 15:19)

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

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

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.

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?

Try trunk?

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

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?

(Last edited by fpaliuc on 23 Feb 2011, 14:07)

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.

(Last edited by written_direcon on 24 Feb 2011, 20:56)

Thanks for all and Great Thanks for  written_direcon )))

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

written_direcon wrote:

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.

Great, thanks ! building A Adjustment - target - mr3020

regards...

Backfire needs to be patched,https://github.com/danitool/openwrt-legacy-buildroot-fixes.

    10-backfire-buildfix-use_feeds_from_git_servers.patch     Use feeds from GIT servers since svn servers are no longer available

The discussion might have continued from here.