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

Shibby "108" Build Issues

Discussion in 'Tomato Firmware' started by jerrm, Mar 12, 2013.

  1. jerrm

    jerrm Network Guru Member

    Hopefully this will save others some time...

    Just ran through a couple of attempts build attempts using a virgin git pull of tomato-shibby-RT-N. I was making the r2e target. This was on unbuntu 12.04. Same VM I had built previous releases with.

    First attempt halted with lzo looking for gawk. Seems to be a new dependency, apt-get was an easy fix.

    Second attempt halted on openvpn. The file ltmain.sh is missing from git. I backed up the tomato source openvpn folder, grabbed the 1.01c tar file, extracted it to the tomato openvpn folder, then copied the original tomato folder back over the extracted version. Sort of a shotgun approach, but figured it would catch all missing files, and pick up any mods that may have been made.

    Third run success!
     
  2. FrancoisC

    FrancoisC Network Guru Member

    Any update on this? Your method may work, but I'm wondering what the root cause is.
     
  3. jerrm

    jerrm Network Guru Member

    Jugster took the time to do some real research here: http://www.linksysinfo.org/index.ph...client-beta-testing.33858/page-19#post-224494.

    The ltmain.sh file was added to the OpenVPN 2.3 source, but did not make it's way to git when Shibby updated Tomato to 2.3.

    Whether Shibby intentionally omitted from git. or if it was an oversight, or his tool chain doesn't need it, I don't know. There are about 20 other packages under /router with their own ltmain.sh, so I would tend to believe it should be there for openvpn as well.
     
    JugsteR likes this.
  4. JugsteR

    JugsteR Serious Server Member

    Thanks. Will update my own branch at the earliest convenience. Also I'm trying this on a 12.10 lubuntu, so I'm almost expecting more problems :)

    Signature? Signature!
     
  5. jerrm

    jerrm Network Guru Member

    I didn't keep notes, so hopefully this has it all, but my steps for 12.10:

    Followed koitsu's how-to http://koitsu.wordpress.com/2012/12/21/instructions-for-building-tomatousb-toastman-rt-n-firmwares/. One change - I put "/opt/brcm/hndtools-mipsel-linux/bin:/opt/brcm/hndtools-mipsel-uclibc/bin" first in the path. Don't know if that makes any difference.

    Installed pkg-config and gawk.

    Copied the file ltmain.sh and the m4 folder from the OpenVPN 2.3.0 source tar to tomato/release/src/router/openvpn.

    Either edit configure.in or set the environment variable for libnfsidmap - see AC_FUNC_MALLOC build issues as described here: http://www.linksysinfo.org/index.ph...rors-on-latest-shibby-rt-n.68150/#post-224435.

    make clean before the first build attempt - the lzo folder from git has a rogue copy of libtool in it.

    Built r64z and it is running now, seems OK, but I haven't tried to test everything yet.
     
  6. JugsteR

    JugsteR Serious Server Member

    This did get me a little bit on the way. However openssl also fails to build, there are some reports on how to get it to build but I'm so far unable to get it to build on my machine. Something about the Makefile not including all source files, however after adding missing files I still get some undefined symbols. I am able to build that component manually, just not during the building of a firmware. Strangely enough this fails on _some_ Ubuntu distributions, and as luck would have it, mine is one of them apparently. ;)

    Signature? Signature!
     
  7. Toastman

    Toastman Super Moderator Staff Member Member

    Just took a quick look at this. I have not investigated this further, but ltmain.sh is probably missing because git / git-gui apparently doesn't recognize that it has been added to the directory and git isn't udpated. Anyone else checked it? I can't say I ever experienced this before, so I am not sure if this behaviour is intended or not. Am I missing something obvious here? Anyone?

    EDIT - it's in the .gitignore file ... !!!

    I never got Ubuntu to work well, I still use Mint. Unless u need your hair shortened prematurely, I'd recommend you dump Ubuntu.
     
  8. jerrm

    jerrm Network Guru Member

    Wish I could say, but I haven't been up to date on Linux build tools for about six years now. If I recall correctly Git had been around for a couple of years, but was just beginning to really catch at that point. My main reason for dusting off the old skills now is I want a build capable of ssl/stls email without resorting to optware/entware. My intention at this point is to try and get openssl s_client working.

    Maybe I was lucky having what few issues I've had so far, but I am in no way married Ubuntu. What version of Mint are you using?
     
  9. koitsu

    koitsu Network Guru Member

    The filename "ltmain.sh" sounds extremely reminiscent of libtool ("lt"). Oh look, sure enough, this one's even more cute because it's an interoperability issue between autoconf and libtool (bhahaha): http://www.gnu.org/software/automak...or-required-file-ltmain_002esh-not-found.html

    So this would classify as another GNU autotools issue of sorts. Sigh.

    This is why the entire TomatoUSB build infrastructure needs to be revamped -- it operates under the (bad) assumption that the autotools (autoconf/automake) and libtool on the users' system is in a sane/usable state and matches that of the developers systems. This is quite often not the case; for example some makefiles may automatically call "autoconf" to rebuild configure from configure.in, and "autoconf" on User X's system may refer to autoconf 2.69, while on another may refer to autoconf 2.51.

    The GNU autotools are notorious for being broken even between minor version changes -- the same goes for libtool.

    The way that this has historically been solved is for the developers/maintainers to commit the necessary configure scripts (e.g. they run autoconf/etc. on their own systems where the firmware is known to build correctly, then commit the results), and also ensure that things like "make distclean" (which tend to nuke configure + force you to regenerate it using autoconf) aren't used anywhere in the build infrastructure. It varies per every third-party software though; some treat "make clean" the same as "make distclean". The same goes for Makefiles (automake) and any other related bits. The problem is that many Makefiles refer to libtool to spawn the compiler/linker (rather than just using CC and LD directly), and if libtool on a users' system differs from that of the developer... well, you get the point by now I think.

    All this utter pain is due to the GNU autotools and friends -- tools that never should have been invented to begin with, IMO.

    There's nothing that can be done sanely about all of this at this time, barring telling the users in official documentation "to build TomatoUSB you need to use automake x.yz, autoconf x.yz, and libtool x.yz -- other versions may/will not work correctly".

    Honestly this sort of stuff is exactly why I prefer Entware for all the "extra" stuff -- because the build infrastructure there and the underlying packages/tools are managed better (no offence to any of the firmware devs, most of this isn't their fault, they're just dealing with the aftermath).

    {rant} I've always been of the opinion that TomatoUSB should go the route of being a bare-bones-minimal firmware with no third-party software, and for the added features/etc. people want, do what OpenWRT does and offer them in package form and write the necessary code to make all of this work dynamically. It's something I've considered working on many, many times over the years but can't be arsed to do so because there are so many caveats and limitations given the limitations of the embedded platform environment. The project I've considered the most is using OpenWRT for the kernel + drivers + and very specific userland bits (as few as possible), with the GUI bits being done from scratch (webserver being lighttpd) and made to be "Tomato-like" (as I cannot stand OpenWRT's GUI interface) and made compatible with OpenWRT (which uses filesystem-based configuration files more than NVRAM variables). {/rant}
     
  10. koitsu

    koitsu Network Guru Member

    Oh, one idea I just thought of -- I guess you could include autoconf, automake, and libtool as part of the initial toolchain tools that have to be built (e.g. /opt/brcm/hndtools-mipsel-linux/bin or /opt/brcm/hndtool-smipsel-uclibc/bin would contain autoconf, automake, and libtool binaries that are known to work correctly with TomatoUSB), then in the underlying build infrastructure, ensure that those are used instead of the ones in say /usr/local/bin.

    That's sad/depressing but might be what's ultimately required to ensure consistency across the board. God I hate autotools and friends.
     
  11. JugsteR

    JugsteR Serious Server Member

    @Toastman Any specific version of Mint I should be using? I always tend to use the latest version of everything, be it router firmwares or operating systems in general. I would feel uneasy if the only thing I could compile this on would be an out of date version of Linux... But better to compile than living on the bleeding edge I guess... (I see now that jerrm beat me to this question, but I don't feel like erasing it when I have written this much)

    @Koitsu I have said it before and I say it again, I just love your posts =) When you think they couldn't get any more detailed, you add a rant. =) I do like your suggestion.

    Is there any other compiler than the one in the repository that could possible compile this? I know there are newer mips compilers, I guess they would be hard to fit in all of this.
     
  12. Toastman

    Toastman Super Moderator Staff Member Member

    I am using the latest version of Mint, whatever stupid name it has. Although it's based on Ubuntu, apparently, unlike Ubuntu it mostly works. Mint's drivers sort of work sometimes if you're lucky, even managed to get 2 of my 4 monitors working and sometimes the sound works correctly too. But hey, this is all modern mainstream gear I use, I expect it'll be supported in a few years time.

    [And the childish half finished semi-working broken and prehistoric apps for Linux?? Every time I use Linux I feel like screaming, to be honest.]

    I have several past versions of Mint, all of them work to compile tomato with no problems. Ubuntu has always given problems.

    I wouldn't ever worry about an out of date version of Linux. Use whatever works and is stable. Older versions may well be better.
     
  13. jerrm

    jerrm Network Guru Member

    I agree to a point, but I wouldn't want it to be too minimalist. One thing I like about Tomato is it is the closest I can get to what I want "out of the box."

    Shibby's VPN or Toastman's VLAN-VPN builds are pretty close to where I'd start my base build, but even then, strip out most if not all of the NAS/FTP/DLNA/Samba features. You'd end up with a build that arguably does everything a Tomato "firewall/router" should, and might have a useable amount of jffs on an 8MB flash.

    Add back in enough GUI and script to make creating a /opt partition in jffs or usb (or possibly even cifs) end-user friendly, with support for adding the third party stuff we already have, and maybe a little more. Create a backup script with gui links that grabs the useful stuff out of nvram, and any additional installed features listing and setup data out of /opt/etc.

    All basic routing/security should be functional if jffs/usb is erased or missing.
     
  14. JugsteR

    JugsteR Serious Server Member

    It is possible to add, just use the force (-f) parameter and do it from command line. It has at least been successfully added to my branch that won't compile for other reasons.

    Signature? Signature!
     
  15. Toastman

    Toastman Super Moderator Staff Member Member

    Jerrm - haha. I have been considering doing just that for a long time. Your take is interesting. Except that I'm not interested in doing anything to stick any crap back in afterwards.
     
  16. jerrm

    jerrm Network Guru Member

    Personally, I'd probably be fine with that.

    But...

    It would be nice for the more "featured" builds - add a hook in the gui to insert menu items, a page to setup an /opt partition and install Entware, and a few check boxes to install/enable a few popular Entware packages, along with a small "Tomato-PackageName-GUI" package. If someone got it up and running, I'd bet the additional size would be below the 100K range added to the base..
     
  17. JugsteR

    JugsteR Serious Server Member

    There already is a build like that. It is called openwrt. ;)

    Signature? Signature!
     
  18. jerrm

    jerrm Network Guru Member

    There is a lot to like with OpenWRT, but I want my Tomato QOS and gui. Like koitsu, I don't like the interface. A lot of it is just familiarity, but it always seems to take more futzing around with OpenWRT.
     
  19. koitsu

    koitsu Network Guru Member

    In my case, the last time I tried OpenWRT (roughly 3-4 months ago), I kept finding ways to "break" their GUI, especially with regards to wireless setting adjustment. OpenWRT's web interface (what they call LuCI) is still under a good amount of development -- and while as a programmer I deeply appreciate Lua and the underlying model/method they're using with their web interface, I just kept running into wonky situations. The problems seemed to stem from their "change queue" mechanism, which I think is a logical/wise idea but there seem to be a lot of edge cases where this doesn't work quite right.

    Almost everything else, however, I really appreciated/enjoyed.

    I don't think the Tomato bits could literally be ported/moved to OpenWRT due to licensing; the Tomato webserver is proprietary (and under a license that nobody is quite sure of -- this licensing problem still plagues TomatoUSB today, because Jonathan Zarate doesn't appear to respond to Emails/etc. or answer questions about the licensing), has some form of pseudo-ASP support, and the GUI bits (including CSS, etc.) are all under that same license. Someone would have to sit down and re-write stuff from scratch, and (preferably) use the webserver that OpenWRT uses. I have my own opinions of that as well -- I'd actually end up using lighttpd and probably use CGIs to do back-end stuff (I am anti-Javascript for most things, but not enough to advocate things like NoScript).
     
  20. Mangix

    Mangix Networkin' Nut Member

    Try Gargoyle: http://www.gargoyle-router.com/

    Funny you say that as most router web interfaces(including Gargoyle) use JavaScript to lessen the workload for the routers themselves and have most of the computationally expensive stuff happen clientside.
     
  21. koitsu

    koitsu Network Guru Member

    This sounds like partial nonsense -- and I say that as someone who ran a co-located hosting organisation for over 15 years.

    I've yet to see Javascript do anything "computationally expensive" that pertains to router tasks, and I've yet to see a case where using client-side Javascript offers any advantage over a server-side CGI when it comes to those tasks. For example, rewriting the OpenWRT configuration files in /etc would be something that would have to be done server-side, not client-side.

    One example where JS is useful is for things like the user interface bits when it comes to adding multiple port forwards before clicking Save -- that's reasonable/legit, because otherwise the user has to add one, click Save, wait for the router to reload rules, page refresh, blah blah -- then add the next one, rinse lather repeat. JS makes this easier (and it has nothing to do with computations) by allowing dynamic creation of multiple HTTP form variables (one for each forwarding rule) that can get submit to the server in a single HTTP POST. Basically it's a way of providing an improved UI, which has the additional benefit of some server-side CPU time savings in very specific circumstances.

    I still remember 1st-and-2nd-gen firmwares, where the webserver that the router ran was horribly slow and did awful things like leave sockets lingering around for long periods of time (300+ seconds). DD-WRT, if I remember right, suffered from this problem for ages and may still today, I don't know. That partially stemmed/stems from use of a crappy webserver and badly-designed garbage. It doesn't have to be that way, and it doesn't have to involve Javascript. But like I said, in the above example (port forwards), using JS to improve the UI is perfectly reasonable. I just think JS happens to be used heavily today, about 80-90% of the time, for wrong/stupid reasons.

    Anyway, this is way, WAY off-topic WRT Shibby 108 build issues, so I'm going to bow out at this point.
     
  22. JugsteR

    JugsteR Serious Server Member

    Using Linux Mint 14 (on xfce) I am able to get past the previous problems fortunately.
    Unfortunately, there is still some work left todo before it compiles it seems.

    For one, it needed an extra lib, asciidoc, which was a couple of hundred MB big =) (with deps)
    Also nfs-util seems to want libnfsidmap, but in the package manager there is only nfsidmap2 available, and it doesn't seem to work with that. Do I really need to install it manually (if possible)?
     
  23. Kevin Darbyshire-Bryant

    Kevin Darbyshire-Bryant Networkin' Nut Member

    I'm probably being really stupid here, but isn't the problem that the openvpn/.gitignore file contains 'ltmain.sh' (and many others) so git is doing the right (but not helpful) thing and ignoring it.
     
  24. JugsteR

    JugsteR Serious Server Member

    You can force it even if in the ignore file.

    I just managed to compile an aio version from the repo, hurray! Takes some 77 minutes to compile on that particular machine.

    Strange that you can't clean everything within git to have a clean environment though. None of the usual tricks works for me. Tar is you friend.

    Signature? Signature!
     
  25. Jacky444

    Jacky444 Addicted to LI Member

    I keep failing at compiling OpenVPN now. I believe i downloaded wrong version of OpenVPN bah...
     
  26. Jacky444

    Jacky444 Addicted to LI Member

    Code:
    (CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash /home/jacky/tomatort/tomato/release/src/router/openvpn/missing --run autoheader)
    rm -f stamp-h1
    touch config.h.in
    cd . && /bin/bash ./config.status config.h
    config.status: creating config.h
    config.status: config.h is unchanged
    make  all-recursive
    make[6]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn'
    Making all in build
    make[7]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build'
    Making all in msvc
    make[8]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build/msvc'
    Making all in msvc-generate
    make[9]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build/msvc/msvc-generate'
    make[9]: Nothing to be done for `all'.
    make[9]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build/msvc/msvc-generate'
    make[9]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build/msvc'
    make[9]: Nothing to be done for `all-am'.
    make[9]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build/msvc'
    make[8]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build/msvc'
    make[8]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build'
    make[8]: Nothing to be done for `all-am'.
    make[8]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build'
    make[7]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/build'
    Making all in distro
    make[7]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/distro'
    Making all in rpm
    make[8]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/distro/rpm'
    make[8]: Nothing to be done for `all'.
    make[8]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/distro/rpm'
    make[8]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/distro'
    make[8]: Nothing to be done for `all-am'.
    make[8]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/distro'
    make[7]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/distro'
    Making all in include
    make[7]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/include'
    make[7]: Nothing to be done for `all'.
    make[7]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/include'
    Making all in src
    make[7]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/src'
    Making all in compat
    make[8]: Entering directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/src/compat'
    /bin/bash ../../libtool --tag=CC  --mode=compile mipsel-uclibc-gcc -DHAVE_CONFIG_H -I. -I../..  -I/home/jacky/tomatort/tomato/release/src-rt/router/lzo/include -I/home/jacky/tomatort/tomato/release/src-rt/router/openssl/include  -O3 -Wall -DLINUX26 -DCONFIG_BCMWL5 -pipe -DBCMWPA2 -funit-at-a-time -Wno-pointer-sign -mtune=mips32 -mips32  -DTCONFIG_NVRAM_64K -ffunction-sections -fdata-sections -MT compat-dirname.lo -MD -MP -MF .deps/compat-dirname.Tpo -c -o compat-dirname.lo compat-dirname.c
    mv -f .deps/compat-dirname.Tpo .deps/compat-dirname.Plo
    mv: cannot stat `.deps/compat-dirname.Tpo': No such file or directory
    make[8]: *** [compat-dirname.lo] Error 1
    make[8]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/src/compat'
    make[7]: *** [all-recursive] Error 1
    make[7]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn/src'
    make[6]: *** [all-recursive] Error 1
    make[6]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn'
    make[5]: *** [all] Error 2
    make[5]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/openvpn'
    make[4]: *** [openvpn] Error 2
    make[4]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router'
    make[3]: *** [all] Error 2
    make[3]: Leaving directory `/home/jacky/tomatort/tomato/release/src-rt'
    make[2]: *** [bin] Error 2
    make[2]: Leaving directory `/home/jacky/tomatort/tomato/release/src-rt'
    make[1]: *** [z] Error 2
    make[1]: Leaving directory `/home/jacky/tomatort/tomato/release/src-rt'
    make: *** [r64z] Error 2
    jacky@defikon:~/tomatort/tomato/release/src-rt$
    
    I can't get pass this, even after redownloading git 3x and adding proper ltmain.sh :/
     
  27. JugsteR

    JugsteR Serious Server Member

    For me it was not enough just adding ltmain.sh. I removed the entire openvpn folder and replaced it we with the folder in the tar file of the openvpn 2.3.0 archive. You have to rename the folder to openvpn though.

    Also if you do a "tar cvzf tomato.tgz tomato" you don't have to waste bandwidth downloading a fresh repo every time. Then you just "tar xvfz tomato.tgz" and it will give you a fresh tomato directory. This of course assumes you did it on a fresh repo.

    Signature? Signature!
     
  28. Jacky444

    Jacky444 Addicted to LI Member

    I will try thanks for tip. Gona post results

    Code:
    make[6]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/lzo'
    make[5]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router/lzo'
    cd openvpn && CFLAGS="-O3 -Wall -DLINUX26 -DCONFIG_BCMWL5 -pipe -DBCMWPA2 -funit-at-a-time -Wno-pointer-sign -mtune=mips32 -mips32  -DTCONFIG_NVRAM_64K -ffunction-sections -fdata-sections" \
            LDFLAGS="-L/home/jacky/tomatort/tomato/release/src-rt/router/openssl -L/home/jacky/tomatort/tomato/release/src-rt/router/lzo/src/.libs -ffunction-sections -fdata-sections -Wl,--gc-sections" \
            CPPFLAGS="-I/home/jacky/tomatort/tomato/release/src-rt/router/lzo/include -I/home/jacky/tomatort/tomato/release/src-rt/router/openssl/include" \
            ./configure --host=mipsel-linux --build=i686-linux-gnu --prefix= \
            --with-crypto-library=openssl \
            --with-iproute-path="/usr/sbin/ip" \
            --disable-debug --disable-plugins --enable-management --enable-small \
            --disable-selinux --disable-socks --enable-password-save \
            OPENSSL_SSL_CFLAGS="-I/home/jacky/tomatort/tomato/release/src-rt/router/openssl/include" \
            OPENSSL_SSL_LIBS="-L/home/jacky/tomatort/tomato/release/src-rt/router/openssl -lssl" \
            ac_cv_lib_resolv_gethostbyname=no
    /bin/sh: 1: ./configure: Permission denied
    make[4]: *** [openvpn/.conf] Error 126
    make[4]: Leaving directory `/home/jacky/tomatort/tomato/release/src/router'
    make[3]: *** [all] Error 2
    make[3]: Leaving directory `/home/jacky/tomatort/tomato/release/src-rt'
    make[2]: *** [bin] Error 2
    make[2]: Leaving directory `/home/jacky/tomatort/tomato/release/src-rt'
    make[1]: *** [z] Error 2
    make[1]: Leaving directory `/home/jacky/tomatort/tomato/release/src-rt'
    make: *** [r64z] Error 2
    
    oh god these errors lol. This happend after full replace of openvpn folder. :/
     
  29. koitsu

    koitsu Network Guru Member

    That error looks like user mistake of some sort, re: "I replaced the openvpn folder, and now all my files are perm 0644".
     
  30. Jacky444

    Jacky444 Addicted to LI Member

    rofl, I didn't think of that. lol. anyway after changing chmod to 0777 for all files and username jacky & group jacky (as my username) still doesn't work. same permission error.

    P.S.: Checked for file in openvpn dir .configure/.conf and it doesn't exist rofl... and OpenVPN folder has 0777 perm on jacky so...

    P.P.S.: I've just found out err didn't came cause of permissions, I removed .conf which was there before. =/ that's fixed.

    I can't believe ! The build went through!!!! Finally :p
     
  31. JugsteR

    JugsteR Serious Server Member

    Easy as pie!

    Big thanks to all developers that actually manage to get something done in this mess. :)

    Signature? Signature!
     
  32. Jacky444

    Jacky444 Addicted to LI Member

    rofl I definitely drink to that.
     
  33. Toastman

    Toastman Super Moderator Staff Member Member

    Just looking at it here. I can't get it to compile. Stuck with same errors as Jacky444 post #26
     
  34. JugsteR

    JugsteR Serious Server Member

    If you are talking about openvpn... I replaced the entire directory with the 2.3.0 tar file that you can download from some official page. Just replacing the ltmain.sh did not work for me. And with replace I mean remove first.

    Signature? Signature!
     
  35. Toastman

    Toastman Super Moderator Staff Member Member

    Tried that, no change.

    I will add, shibby's branch compiles here, but when I try to add to my own branch I get this issue. Scratching my head somewhat here. I started from scratch but still get the same problem. And also if I simply replace the entire openvpn directory with the one from shibby's last git post.

    I hesitate to ask shibby if he has any idea at the moment, because he is very busy with work. I'll wait, it's not important.
     
  36. JugsteR

    JugsteR Serious Server Member

    Exactly what branch fails? Is it something we could try to replicate?

    Signature? Signature!
     
  37. Toastman

    Toastman Super Moderator Staff Member Member

    Just try to add it to the Toastman-RT branch. See what happens for you.
     
  38. JugsteR

    JugsteR Serious Server Member

    I checked out your branch (git checkout -b origin/Toastman-RT)
    make distclean
    make r2z (completed successfully)
    make distclean
    (remove openvpn folder, and copy in new openvpn folder)
    make r2z (completed successfully)
     
  39. Toastman

    Toastman Super Moderator Staff Member Member

    curious.

    My makefile doesn't have r2z as a build. ?? Isn't that shibby's All-In-One build?
     
  40. koitsu

    koitsu Network Guru Member

    Yep, you guessed it (see bottom of file).
     
  41. JugsteR

    JugsteR Serious Server Member

    I was under the impression that I checked out your branch with that command but apparently not. I have now done that and it is compiling your branch. Will get back to you in two hours or so when it has finished

    Signature? Signature!
     
  42. Toastman

    Toastman Super Moderator Staff Member Member

    I'm glad I have a fast machine, if I had to wait 2 hours I think I'd commit suicide.
     
  43. JugsteR

    JugsteR Serious Server Member

    Be careful what you speak, or otherwise you might have a death on your hands =)

    Anyway, I have fast machines as well, it just so happens that this particular machine is doing nothing, so it might as well serve as compiler for different things...

    git log
    commit 975463400ddb9b5fd30edddaf35ecdc01048bb7c
    Author: Toastman <toastman@galactic_core>
    Date: Wed Mar 27 16:34:03 2013 +0700

    Fix for dhcpv6 with prefix delegation

    // eval("ip", "route", "add", "::/0", "dev", (char *)wan_ifname); //removed by Toastman
    // see discussion at http://www.linksysinfo.org/index.php?threads/ipv6-and-comcast.38006/
    // post #24 refers.

    commit 01f1caa077ec031c211d9d0fcfa6a565530db985
    Author: Kevin <kdbtomato@darbyshire-bryant.me.uk>
    Date: Sat Feb 23 10:33:29 2013 +0100

    Dnsmasq: update to 2.66TEST16

    commit c676abb1108945dd0074096a112919ed3b2cc3ca
    Author: Shibby <shibby@openlinksys.info>
    Date: Mon Jan 21 21:17:51 2013 +0100

    fix openssl compilation when FULL_OPENSSL is not defined

    commit 12052105b251ce517b3d77f48bb38b6c9d43877b
    Author: Shibby <shibby@openlinksys.info>
    Date: Tue Jan 15 11:31:47 2013 +0100
    ...

    I think this is the correct branch?

    * Toastman-RT 9754634 Fix for dhcpv6 with prefix delegation

    If it is, then the result is this:

    Creating TRX: image/tomato-K26USB-1.28.MIPSR2-VPN-NOCAT.trx

    TRX Image:
    Total Size .... : 7479296 (7304.0 KB) (7.1 MB)
    Images ...... : 7476404 (0x007214b4)
    Padding ..... : 2864
    Avail. for jffs :
    4MB, 128K CFE : 0 EBs + 0
    4MB, 256K CFE : 0 EBs + 0
    8MB, 256K CFE : 8 EBs + 57344
    Note : Netgear routers have 6 EBs less available!
    CRC-32 ........ : 42779FC5
    128K Blocks ... : 58 (0x0000003A)
    64K Blocks ... : 115 (0x00000073)
    Offsets:
    0: 0x0000001C lzma-loader/loader.gz
    1: 0x00000AD8 /home/henrik/tomato/release/src-rt/linux/linux-2.6/arch/mips/brcm-boards/bcm947
    2: 0x000E4C00 router/mipsel-uclibc/target.image


    -----------------
    1.28.0000 K26 USB VPN-NOCAT ready
    -----------------
    make[3]: Leaving directory `/home/henrik/tomato/release/src-rt'
    make[2]: Leaving directory `/home/henrik/tomato/release/src-rt'
    make[1]: Leaving directory `/home/henrik/tomato/release/src-rt'

    This is with the openvpn in the repo.
     
  44. shibby20

    shibby20 Network Guru Member

  45. jerrm

    jerrm Network Guru Member

  46. JugsteR

    JugsteR Serious Server Member

    +1

    Signature? Signature!
     
  47. Toastman

    Toastman Super Moderator Staff Member Member

    shibby - we've already done that, but still have strange build problems.
     
  48. JugsteR

    JugsteR Serious Server Member

    If I remove old openvpn, add new one, I get an error while running configure, it says lzoutil.h is missing, even though there is a lzoutil.h file in the ~/tomato/release/src/router/lzo/include/ directory. I do not get this error while on Shibbys branch. Only on Toastman-RT branch.
     
  49. Toastman

    Toastman Super Moderator Staff Member Member

    I've seen that error too, amongst others. Seems like a different one every time.
     
  50. shibby20

    shibby20 Network Guru Member

    Right. I fixed that. Will push changes to GIT a little bit later (but today). Now i`m installing my new builder PC for tomato compilation: Xeon X3210 2,13GHz Quad-Core + 4GB RAM + Debian Wheezy x64 on kernel 3.x) :) Should be faster ;)
     
    Dark_Shadow likes this.
  51. Toastman

    Toastman Super Moderator Staff Member Member

    Great! Interested to know what the problem was. New PC sounds good!
     
  52. shibby20

    shibby20 Network Guru Member

  53. shibby20

    shibby20 Network Guru Member

  54. lolcat

    lolcat Reformed Router Member

    shibby ... csescz... In fact, I would like to ask you a few things about buiolding.. first of all im pu Krakowska, po poznanska ;p but I cant type Polish... Your English is better... 2. thank you very much for these builds.. my wnr3500LV2 really comes to life thanks to your work :)

    3. I however, wonder why you have chosen to stick to a certian kernel , as it has some vulnerabilities I am a bit worried about so... why is it we can't update the kernel.. even to a 3.X build? Is it due to the work needed to rewrite the build scripts? (I presume yesh)... but could you provide any tips .. (and warnings) on what I would have to keep in mind to try and bring the sources more up to date? lzo.. have you tried LZ4?

    Anyway... I had some kernel modules I tried adding on 105, but now seems 108 has it, ntfs.. and iso was missing bla bla.. still.. a small list over what are hte issues or why not use kernel N.XX would be nice.

    I am willing to maybe help compile, rewrite do some dev if I could get some pointers/advice... but I admit.. I am very terrible with automake/config scripts and so on... however, being on arch linux + a nice i7-2600 is great for compiling.. .haha I compiled a kernel in 8 mins the other day.. I think my arch had an issue with frequency setting and compiled @ 5.9 GHZ on AIR LOL but computer is fine... although i fixed it afterwards.. cos 8 mins is just WRONG ,)

    na rascze

    Malina
     
  55. lolcat

    lolcat Reformed Router Member

    oh.. and I know I can dl through {ent/opt}ware useradd or so... as I would like to not use root as the ssh user tbh.
     
  56. Toastman

    Toastman Super Moderator Staff Member Member

    Thanks Michal, will try it tomorrow.
     
  57. Mangix

    Mangix Networkin' Nut Member

    Broadcom's wireless drivers are closed source and compiled against this kernel version. Nothing can be done about this.

    If you want newer kernels, you'd have to use OpenWRT which has open source drivers for Broadcom devices. Hardware support is a bit limited though(although the latest trunk did add support for a bunch of them including the WNDR3400).

    Actually there was a thread about kernel version before. I'll edit this post if I find it.

    edit: Found it: http://www.linksysinfo.org/index.php?threads/speeding-up-the-samba-by-30.52240/#post-202996
     
  58. Toastman

    Toastman Super Moderator Staff Member Member

    lolcat -sorry my friend, but this forum is not to be used as a Linux v. Windows flame war. Post deleted.
     
  59. RDHLLC

    RDHLLC Serious Server Member

    Remind me again, why someone hasn't made a virtualbox or vmware virtual machine that has linux and all the necessary additional software to be a good build environment and made that available to the community for download...???
     
  60. koitsu

    koitsu Network Guru Member

    Because:

    1. The image is going to be multiple gigabytes given how much bullshit Linux pulls in dependency-wise for a dev environment,

    2. The image will immediately become outdated when firmware changes are made that require new packages (such as with Shibby's latest firmware, many new dependencies are required). You can tell me "so then just install those packages, why does that make the image itself outdated", to which I will say "then why not just make the image yourself?" :)
     
  61. RDHLLC

    RDHLLC Serious Server Member

    Ok...so roll your own is just the way it is. I am interested in doing a VM for shibby, and have searched the forum a bit, but can't seem to find much in the way of instructions on what to download and how to do it. I see people saying use Mint instead of Ubuntu but that's about it. Got a link that would start someone off with some decent direction?
     
  62. koitsu

    koitsu Network Guru Member

    http://koitsu.wordpress.com/2012/12/21/instructions-for-building-tomatousb-toastman-rt-n-firmwares/

    More or less the procedure is the same, just for shibby's branch (for branch names see http://repo.or.cz/w/tomato.git under the section called "heads", then use git checkout origin/{name}), and you'll need to figure out on your own what all the other packages are you need to install on the system. Others have posted some which are needed, and the package names which are needed vary depending on Linux distro you're using and so on. I only test with a very specific distro (Debian 6.0.6 and 6.0.7 32-bit) and do not care to deal with other distros.
     
  63. jerrm

    jerrm Network Guru Member

    Has anyone built an image from Shibby's latest git updates?

    The good news is that RT-N VPN targets (r64e & r2e) completed with no issues.

    The AIO targets (r64z & r2z) failed in tor, with an error requiring asciidoc:
    Code:
    make[7]: Entering directory `/home/jerrm/shibby/release/src/router/tor/doc'
    ../doc/asciidoc-helper.sh man none ../doc/tor.1.in
    ==================================
    You need asciidoc installed to be able to build the manpage.
    To build without manpages, use the --disable-asciidoc argument
    when calling configure.
    ==================================
    Obviously we don't need the man page, but I'm scratching my head over why the error has popped up. I ran a diff against my "virgin108.git" folder pulled from git before the last updates and don't see anything that should cause this. Only the changes listed in the git commits are shown.

    Any ideas? Has anyone else seen this?

    Other than this new issue, the AIO targets still need the AC_FUNC_MALLOC fix on my system.

    I'm using Ubuntu 12.10 32bit.
     
  64. Mangix

    Mangix Networkin' Nut Member

    sudo apt-get install asciidoc
     
  65. jerrm

    jerrm Network Guru Member

    I won't install 1GB of otherwise unnecessary junk for a man page that is not needed. Too easy to work around.

    The main question is what caused the new dependency - I can't find any changes to cause it. Is it a quirk of my system, or something broader?

    Again - has anyone built an AIO or tor target with the new updates?
     
  66. Mangix

    Mangix Networkin' Nut Member

    last time I installed it, it was not 1GB. In any case, why not just edit the makefile in that directory so that --disable-asciidoc gets passed?
     
  67. koitsu

    koitsu Network Guru Member

    Agreed. --disable-asciidoc should be used during the configure phase since man pages aren't part of the firmware; that's something shibby should fix upstream. I'm off to bed right now else I'd provide a diff.
     
  68. jerrm

    jerrm Network Guru Member

    I was shocked when I saw it. The package maintainers are probably pulling in too much stuff "just to be safe" but 1GB is ridiculous.

    Code:
    [EMAIL]j@u-vm:~$[/EMAIL] sudo apt-get install asciidoc
    [sudo] password for j:
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    The following extra packages will be installed:
      dblatex docbook docbook-dsssl docbook-utils docbook-xml docbook-xsl jadetex latex-beamer latex-xcolor libosp5 libostyle1c2
      libptexenc1 libruby1.9.1 libsgmls-perl libsp1c2 libxml2-utils libyaml-0-2 lmodern luatex openjade pgf preview-latex-style prosper
      ps2eps ruby ruby1.9.1 sgml-data sgmlspl sp tex-common tex-gyre texlive texlive-base texlive-bibtex-extra texlive-binaries
      texlive-common texlive-doc-base texlive-extra-utils texlive-font-utils texlive-fonts-recommended texlive-fonts-recommended-doc
      texlive-generic-recommended texlive-latex-base texlive-latex-base-doc texlive-latex-extra texlive-latex-extra-doc
      texlive-latex-recommended texlive-latex-recommended-doc texlive-luatex texlive-math-extra texlive-pictures texlive-pictures-doc
      texlive-pstricks texlive-pstricks-doc tipa ttf-marvosym xmlto xsltproc
    Suggested packages:
      vim-addon-manager source-highlight graphicsmagick-imagemagick-compat imagemagick latex-cjk-all opensp texlive-lang-cyrillic
      texlive-xetex transfig docbook-defguide psgml docbook-dsssl-doc docbook-xsl-doc-html docbook-xsl-doc-pdf docbook-xsl-doc-text
      docbook-xsl-doc libsaxon-java libxalan2-java libxslthl-java docbook-xsl-saxon fop xalan dbtoepub sgmls-doc ri ruby-dev
      ruby1.9.1-examples ri1.9.1 graphviz ruby1.9.1-dev ruby-switch perlsgml w3-recs debhelper texlive-doc-en perl-tk purifyeps chktex
      latexmk dvipng xindy dvidvi fragmaster lacheck latexdiff psutils t1utils libfile-which-perl dot2tex xmltex
    The following NEW packages will be installed:
      asciidoc dblatex docbook docbook-dsssl docbook-utils docbook-xml docbook-xsl jadetex latex-beamer latex-xcolor libosp5 libostyle1c2
      libptexenc1 libruby1.9.1 libsgmls-perl libsp1c2 libxml2-utils libyaml-0-2 lmodern luatex openjade pgf preview-latex-style prosper
      ps2eps ruby ruby1.9.1 sgml-data sgmlspl sp tex-common tex-gyre texlive texlive-base texlive-bibtex-extra texlive-binaries
      texlive-common texlive-doc-base texlive-extra-utils texlive-font-utils texlive-fonts-recommended texlive-fonts-recommended-doc
      texlive-generic-recommended texlive-latex-base texlive-latex-base-doc texlive-latex-extra texlive-latex-extra-doc
      texlive-latex-recommended texlive-latex-recommended-doc texlive-luatex texlive-math-extra texlive-pictures texlive-pictures-doc
      texlive-pstricks texlive-pstricks-doc tipa ttf-marvosym xmlto xsltproc
    0 upgraded, 59 newly installed, 0 to remove and 40 not upgraded.
    Need to get 675 MB of archives.
    After this operation, 1,059 MB of additional disk space will be used.
    Do you want to continue [Y/n]? n
    Abort.
    That is the easy fix, but the best place is the tor section of release/src/router/Makefile, not the tor folder Makefile.

    Again, the fix is easy, but why am I getting it now and not a week ago?
     
  69. jerrm

    jerrm Network Guru Member

    I doubt shibby really needs a diff for this, but if he wants it:
    Code:
    --- tomato.s/release/src/router/Makefile 2013-03-29 20:47:16.556770077 -0400
    +++ tomato/release/src/router/Makefile 2013-03-30 10:34:17.966701453 -0400
    @@ -1914,7 +1914,7 @@
      CFLAGS="-Os -Wall $(EXTRACFLAGS) -ffunction-sections -fdata-sections" \
      LDFLAGS="-ffunction-sections -fdata-sections -Wl,--gc-sections" \
      $(CONFIGURE) --prefix=/usr --with-libevent-dir=$(TOP)/libevent/staged/usr/local \
    -  --with-openssl-dir=$(TOP)/openssl --with-zlib-dir=$(TOP)/zlib
    +  --with-openssl-dir=$(TOP)/openssl --with-zlib-dir=$(TOP)/zlib --disable-asciidoc
      touch tor/stamp-h1
     
    tor: tor/stamp-h1
    
     

    Attached Files:

  70. Kevin Darbyshire-Bryant

    Kevin Darbyshire-Bryant Networkin' Nut Member

    Yes I can compile RT-N but with all the caveats & issues you document above.

    I'm a very git newbie but I've pushed 5 commits to shibby's RT-N branch. Update dnsmasq to 2.66rc3, & 3 fixes related to dnsmasq.conf file generation (committed separately for easy removal etc) & a final commit (a few mins ago) to not build the tor man pages (your easy fix as above)

    These commits ideally need to be copied into the normal Shibby branch and not just the RT-N but I don't know how to do that. And I also suspect I work in the reverse way to Shibby, I think he works on the normal branch and then merges those changes to RT-N branch.

    I really hope Shibby doesn't mind me committing this stuff to his branch.

    Edit: typo
     
  71. jerrm

    jerrm Network Guru Member

    Did you have the asciidoc issue with git immediately after the original 108 commits, or did it start with the "build fix" commits?

    I guess the proper question is why I didn't have the problem with the original 108 git, as it looks like the --disable-asciidoc really should be there.
     
  72. lancethepants

    lancethepants Network Guru Member

    Oh man, I wouldn't dare push to another developers personal branch without their explicit permission. Probably better to create your own and then ask them to incorporate your changes.
     
  73. shibby20

    shibby20 Network Guru Member

    Fresh, new PC + Debian 7.0 x64
    I havent installed asciidoc
    And i haven`t problems with TOR compilation:
    but ok, i will add this option to git.

    @Kevin Darbyshire-Bryant- before you will push any changes to my branches please tell me about this first. I`m not angry but if i will push my changes before "git pull" (i never do this ;) ), then i will overwrite yours changes and all your works will be removed. Please inform me first on PM. I will move your changes to tomato-shibby branch.
     
  74. Kevin Darbyshire-Bryant

    Kevin Darbyshire-Bryant Networkin' Nut Member

    I promise to spend more time reading the manuals to work out how to do the above - the whole branching & merging from other branches and keeping things up to date confuses the hell out of me! I can't help feel it's all branched out enough.

    But if someone could write a real idiots guide to branching and merging tomato I for one would feel a lot happier about even thinking about committing code. It was great nervousness that I asked Keith for write access yesterday...and even more daring to put some code changes out in the wild.
     
  75. Kevin Darbyshire-Bryant

    Kevin Darbyshire-Bryant Networkin' Nut Member

    I can't remember! As soon as I got I just installed asciidoc....and a gigabyte later.... :)
     
  76. jerrm

    jerrm Network Guru Member

    Thanks!

    The odd thing is I can still compile the "original" 108 pull from git without the getting the error. With the fix going in, I guess I won't waste more time, but I hate not being able to figure out why weirdness like this happens.
     
  77. lancethepants

    lancethepants Network Guru Member

    I also had to install asciidoc in order to compile the firmware. I'm using Ubuntu 12.04 & 12.10, so perhaps it's the difference between using vanilla Debian and Ubuntu. No worries now that Kevin patched things up there now.
     
  78. jerrm

    jerrm Network Guru Member

    At least I'm not alone.

    I don't have any affinity for ubuntu, I'll try to get a Deb 7 x64 vm setup in the next day or so and see how it goes.
     
  79. Toastman

    Toastman Super Moderator Staff Member Member

    Welcome to the git repo, Kevin :D

    In general, I would do not myself, nor advise anyone to push to someone else's branch - with or without their permission. It's been done several times before and created an embarrassing situation where the push was done with good intentions but actually screwed up more things in the other person's branch than it fixed. Trying to fix this by deleting the push can also caused a situation where people then complained that git history has been changed, affecting everyone's git copy who has cherry picked or merged that code.

    I for one no longer "merge" branches into my own, I use individual cherry picks so that I have more control over what is included.

    General tips on using git:

    If you have serious code to contribute, create your own branch (e.g. beginning with the build of your choice, add your stuff, and then give it a new branch name before pushing). Generally we will work on the "base" (or simplest) branch and later merge that branch into any others. Post in a new thread exactly what you did and why, and let others make the choice of whether to include it or not, i.e. don't try to "force" people to use it. We all read the threads, no need to multiple post or bump. If other people want to use it, they can then cherry-pick the commits into their own branches.

    Make sure your git commits relate to ONE change at a time. Making a commit that changes several different things at once is confusing and often means that people can't use your code without spending time identifying and editing out the parts they don't want.

    Please do be careful with the use of git when you have push permissions. There have been occasions where accidental deletion of Teddy's and several other branches occurred, which I had to restore from local backups. With some graphical interfaces to git, it's easy to do that without meaning to, or even knowing that you did it.

    Lastly, you may care to get used to working with one of the GUI's that are available for git. The gitk and git-gui utils that come with git install are extremely easy to use and will speed up your work no end. Smartgit is generally thought of as being one of the better (more full-featured) GUI's but it has a more steep learning curve. (I remember Fedor (Teddy Bear) asking me once how on earth I cherry picked, edited, and merged his code and re-uploaded it within minutes of his pushing it to git).
     
  80. shibby20

    shibby20 Network Guru Member

    You already have local copy of GIT, well first of all do:
    to download latest changes in git.

    Then create a local copy of your favorite branch( ie tomato-shibby-RT-N).
    You will be switched automatically to new branch. To check work branch you can use command
    Selected and active branch will be with *, like this:
    Mine active branch is tomato-shibby-RT-N. You will have tomato-kevin-RT-N

    To switch local "active" branch you can use command:
    Now you can make changes and create commits. If you added or modified files, then you can use command
    to apply all added/changed files

    If you removed a file then
    if you removed a lot of files then
    should help

    Always check a status before create new commit
    And commit changes
    if mesage is short or just
    this will open default text editor. Write a message and save. Commit will be create

    Merging branch (all changes) from tomato-shibby-RT-N to tomato-kevin-RT-N (tomato-kevin-RT-N must be selected as active)
    Process is automatically. If all will be good, then commit will be created also automatically. If you will have some errors, then you have to fix them and then
    Cherry-pick one commit from another branch.
    For example: http://repo.or.cz/w/tomato.git/commit/975463400ddb9b5fd30edddaf35ecdc01048bb7c
    How to move/copy this commit to your branch? Copy commit ID (in this case it is 975463400ddb9b5fd30edddaf35ecdc01048bb7c, and then
    Commit will be copied automatically. If you will have some errors then you have to fix them and
    This solution allow you to leave Author/Message without changes.

    If someone was made some changes if you branch (as you did in mine) and you want to leave them, then before push your changes to remote GIT, you have to synchronize remote branch with local branch.
    This will copy and apply all new commit from remote to local branch. Now you can push changes to remote GIT
    I hope this will have you :)
     
  81. Kevin Darbyshire-Bryant

    Kevin Darbyshire-Bryant Networkin' Nut Member

    Thanks Shibby. My new favourite post :)
     

Share This Page