1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
Dismiss Notice

Welcome To SNBForums

SNBForums is a community for anyone who wants to learn about or discuss the latest in wireless routers, network storage and the ins and outs of building and maintaining a small network.

If you'd like to post a question, simply register and have at it!

While you're at it, please check out SmallNetBuilder for product reviews and our famous Router Charts, Ranker and plenty more!

Compile asuswrt-merlin.ng for RT-AC5300

Discussion in 'Asuswrt-Merlin' started by bmn1, Oct 13, 2018 at 11:36 AM.

  1. bmn1

    bmn1 Regular Contributor

    Joined:
    May 17, 2011
    Messages:
    141
    I tried to compile the source code but without success!!!

    I follow the tuto from here

    https://github.com/RMerl/asuswrt-merlin/wiki/Download-the-latest-source-code-from-GitHub done

    1. Compile from source using Ubuntu -> ERROR
    2. Compiling from source using a Debian-based Linux Distribution ERROR
    I tried Ubuntu 12, Ubuntu 14, Ubuntu 16, Ubuntu 18 and the same result not get compiled I TRIED IN x86 and x64 and the same result....

    I have in home directory https://github.com/RMerl/am-toolchains too.

    And all automated scrips for compile are from 2015 and don't work.

    Any recent tuto for RT-AC5300?


    I tried other models and get results like this

    [​IMG]
     
    Last edited: Oct 13, 2018 at 11:48 AM
  2. Please support SNBForums! Just click on this link before you buy something from Amazon and we'll get a small commission on anything you buy. Thanks!
  3. Odkrys

    Odkrys Senior Member

    Joined:
    Jul 28, 2016
    Messages:
    255
    it seems you were in wrong folder.

    Edit. sorry I didn't see "tried other models".
    There is error message. You need to install liblzo2-dev.
    Here is the list what I installed to compile merlin firmware.
    Code:
    dpkg --add-architecture i386
    
    apt-get update
    
    apt-get install libncurses5 libncurses5-dev m4 bison gawk flex \
    g++ gengetopt git gitk zlib1g-dev autoconf autopoint \
    libtool shtool autogen mtd-utils intltool sharutils libstdc++5 texinfo \
    dos2unix xsltproc u-boot-tools device-tree-compiler python qemu \
    gperf liblzo2-dev uuid-dev build-essential lzma-dev liblzma-dev \
    lzma binutils-dev patch cmake libglib2.0-dev gtk-doc-tools \
    libc6-i386 lib32stdc++6 lib32z1 libelf1:i386 libncurses5:i386 libc6-dev-i386 \
    bc libtool-bin gnulib xutils-dev libltdl-dev
    
     
    Last edited: Oct 13, 2018 at 1:06 PM
    bmn1 likes this.
  4. bmn1

    bmn1 Regular Contributor

    Joined:
    May 17, 2011
    Messages:
    141

    That picture was for other model but for my router RT-AC5300 is
    For RT-AC5300
    cd ~/asuswrt-merlin.ng/release/src-rt-7.14.114.x/src/

    I will continue trying. Sorry for my bad english XD
     
  5. bmn1

    bmn1 Regular Contributor

    Joined:
    May 17, 2011
    Messages:
    141
    This error is the more actual

    /usr/bin/install: cannot stat './xmllint.1': No such file or directory
    /usr/bin/install: cannot stat './xmlcatalog.1': No such file or directory
    Makefile:505: recipe for target 'install-man1' failed
    make[8]: *** [install-man1] Error 1
    make[8]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src/router/libxml2/doc'
    Makefile:716: recipe for target 'install-am' failed
    make[7]: *** [install-am] Error 2
    make[7]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src/router/libxml2/doc'
    Makefile:555: recipe for target 'install-recursive' failed
    make[6]: *** [install-recursive] Error 1
    make[6]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src/router/libxml2/doc'
    Makefile:1398: recipe for target 'install-recursive' failed
    make[5]: *** [install-recursive] Error 1
    make[5]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src/router/libxml2'
    Makefile:7929: recipe for target 'libxml2-stage' failed
    make[4]: *** [libxml2-stage] Error 2
    make[4]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src/router'
    Makefile:5136: recipe for target 'libxml2' failed
    make[3]: *** [libxml2] Error 2
    make[3]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src/router'
    Makefile:416: recipe for target 'all' failed
    make[2]: *** [all] Error 2
    make[2]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src-rt-7.14.114.x/src'
    Makefile:3918: recipe for target 'bin' failed
    make[1]: *** [bin] Error 2
    make[1]: Leaving directory '/home/ubuntu18/asuswrt-merlin.ng/release/src-rt-7.14.114.x/src'
    Makefile:4060: recipe for target 'rt-ac5300' failed
    make: *** [rt-ac5300] Error 2
     
  6. bmn1

    bmn1 Regular Contributor

    Joined:
    May 17, 2011
    Messages:
    141
    in the post say for ubuntu >13

    cd ~/asuswrt-merlin.ng/release/src/router/libxml2
    sed -i s/AM_C_PROTOTYPES/#AM_C_PROTOTYPES/g ~/asuswrt-merlin/release/src/router/libxml2/configure.in
    aclocal

    but configure.in is not supported anymore need be configure.ac this message say when you run aclocal.
     
  7. bmn1

    bmn1 Regular Contributor

    Joined:
    May 17, 2011
    Messages:
    141

    Thanks now is compile fine.
     
  8. RMerlin

    RMerlin Super Moderator

    Joined:
    Apr 14, 2012
    Messages:
    27,986
    Location:
    Canada
    Requires the gtk-doc-tools package on your build environment.
     
  9. bmn1

    bmn1 Regular Contributor

    Joined:
    May 17, 2011
    Messages:
    141
    Ubuntu 18.04.1 x64
    sudo dpkg --add-architecture i386
    sudo apt-get update
    sudo apt-get install libncurses5 libncurses5-dev m4 bison gawk flex \
    g++ gengetopt git gitk zlib1g-dev autoconf autopoint \
    libtool shtool autogen mtd-utils intltool sharutils libstdc++5 texinfo \
    dos2unix xsltproc u-boot-tools device-tree-compiler python qemu \
    gperf liblzo2-dev uuid-dev build-essential lzma-dev liblzma-dev \
    lzma binutils-dev patch cmake libglib2.0-dev gtk-doc-tools \
    libc6-i386 lib32stdc++6 lib32z1 libelf1:i386 libncurses5:i386 libc6-dev-i386 \
    bc libtool-bin gnulib xutils-dev libltdl-dev
    git clone https://github.com/RMerl/am-toolchains
    git clone https://github.com/RMerl/asuswrt-merlin.ng
    These are the toolchains used to compile Asuswrt-Merlin firmwares.
    brcm-arm-hnd/ Broadcom HND ARM platform (RT-AC86U)
    brcm-arm-sdk/ Broadcom SDK6/SDK7 ARM platform (RT-AC56 upto RT-AC5300)
    Setup instructions (assuming this repository is cloned under ~/am-toolchains/
    BCM-HND:
    sudo ln -s ~/am-toolchains/brcm-arm-hnd /opt/toolchains
    echo "export LD_LIBRARY_PATH=$LD_LIBRARY:/opt/toolchains/crosstools-arm-gcc-5.3-linux-4.1-glibc-2.22-binutils-2.25/usr/lib" >> ~/.profile
    echo "export TOOLCHAIN_BASE=/opt/toolchains" >> ~/.profile
    echo "PATH=\$PATH:/opt/toolchains/crosstools-arm-gcc-5.3-linux-4.1-glibc-2.22-binutils-2.25/usr/bin" >> ~/.profile
    echo "PATH=\$PATH:/opt/toolchains/crosstools-aarch64-gcc-5.3-linux-4.1-glibc-2.22-binutils-2.25/usr/bin" >> ~/.profile
    BCM-SDK:
    Assuming you have cloned the firmware repository under ~/asuswrt-merlin.ng/ :
    sudo ln -s ~/am-toolchains/brcm-arm-sdk/hndtools-arm-linux-2.6.36-uclibc-4.5.3 /opt/brcm-arm
    ln -s ~/am-toolchains/brcm-arm-sdk ~/asuswrt-merlin.ng/release/src-rt-6.x.4708/toolchains
    echo "PATH=$PATH:/opt/brcm-arm/bin" >> ~/.profile
    cd ~/asuswrt-merlin.ng/release/src-rt-7.14.114.x/src/
    make clean
    make RT-AC5300
     
    Grisu likes this.
Please support SNBForums! Just click on this link before you buy something from Amazon and we'll get a small commission on anything you buy. Thanks!