optware install

Discussion in 'Tomato Firmware' started by Daky, Aug 4, 2013.

  1. Daky

    Daky Network Guru Member

    I am total noob, sorry about this!

    - Add optware-install.h script to Tomato – just mount drive to /opt directory and run „optware-install.sh”. That`a all.

    This is confusing me, i am able to ssh, but, not sure how this should be done from there.

    Could somebody please help me?

  2. koitsu

    koitsu Network Guru Member

  3. Daky

    Daky Network Guru Member


    as usual, BIG thanks!!!!!! you are really BIG help in this community.

    Man, nobody can't beat you with full explanations\instructions and detailed help!

    Thank you very much.
  4. ryzhov_al

    ryzhov_al Addicted to LI Member

    kthaddock, darkknight93 and jerrm like this.
  5. jerrm

    jerrm Network Guru Member

    A second vote. Disappointed 112 only included new Optware script. Much prefer Entware, ideally both should be available.
  6. shibby20

    shibby20 Network Guru Member

    i prefer optware. I`m making my own packages for optware. Why i added optware-install script to tomato? Because:
    - it`s automacically added my repository
    - in my repository is fixed bash package (PATH are correct and arrows works in mc)

    Without those changes i will not see the reason to add install script into Tomato. One wget command and you have entware or extware install script downloaded in /tmp and ready to install.

    Entware`s bash includes both problems. Check yourself. Just install bash and mc packages, do reboot and PATH will be broken (some of command will not work ie: nvram) and arrows in mc will not work - i checked myself. This is why i decide to add optware-install script instead entware.

    Why i prefer optware? Optware has one important advantage over entware. All package works correct on tomato because they are compiled to working correct only with tomato/ddwrt. Entware it`s a openwrt project only compiled with mipsel toolchain (with added prefix /opt i hope, but i`m not sure). As we know openwrt has diffent filesystem then tomato/ddwrt. Tomato/ddwrt has read-only and all packages has to be installed to /opt. Openwrt has read-write filesystem (pivot with jffs). This is why all packages may be installed to root "/" directory. I tried install few packages from entware and not all works correct. Startup and configuration files/scripts are not working on tomato (openwrt doesnt use nvram, all configurations are keeped in /etc/config. Startup script take configuration from /etc/config directory and create configuration file "on-the-fly" for service, then start a service). Tomato can`t save files in /etc directory.

    IMO Entware is not 100% compatible with Tomato. Optware, so.

    @daky: just add to init script this command:
    mount /dev/sda1 /opt

    and save (make sure you have patrition /dev/sda1 and it`s formated as ext2 or ext3 filesystem). Be sure also you have DISABLED automounting in usb setting. Then make reboot. After reboot check usb setting -> device list. You drive should be mounted as /opt. If it does, then log on to ssh/telnet console (you can use putty software) and run command: optware-install.sh

    Thats all.
    Frequenzy likes this.
  7. koitsu

    koitsu Network Guru Member

    I won't comment past this point, but I can't reproduce problems with $PATH using bash. You can clearly see here I'm using the stock Busybox shell, then run Entware bash, and $PATH is the same. I do not use any kind of dotfiles or otherwise, so to me this is the exact/expected behaviour.

    $ telnet gw
    Connected to gw.home.lan.
    Escape character is '^]'.
    gw login: root
    Tomato v1.28.0502 MIPSR2Toastman-RT-N K26 USB Ext
    root@gw:/tmp/home/root# opkg list-installed | grep bash
    bash - 4.2-3
    root@gw:/tmp/home/root# echo $BASH_VERSION
    root@gw:/tmp/home/root# echo $PATH
    root@gw:/tmp/home/root# nvram
    NVRAM Utility
    Copyright (C) 2006-2009 Jonathan Zarate
    Usage: nvram set <key=value> | get <key> | unset <key> |
    ren <key> <key> | commit | erase | show [--nosort|--nostat] |
    find <text> | defaults <--yes|--initcheck> | backup <filename> |
    restore <filename> [--test] [--force] [--forceall] [--nocommit] |
    export <--quote|--c|--set|--tab> [--nodefaults] |
    export <--dump|--dump0> | import [--forceall] <filename> |
    setfb64 <key> <filename> | getfb64 <key> <filename> |
    setfile <key> <filename> | getfile <key> <filename> | setfile2nvram <filename>
    root@gw:/tmp/home/root# /opt/bin/bash
    root@gw:/tmp/home/root# echo $BASH_VERSION
    root@gw:/tmp/home/root# echo $PATH
    root@gw:/tmp/home/root# nvram
    NVRAM Utility
    Copyright (C) 2006-2009 Jonathan Zarate
    Usage: nvram set <key=value> | get <key> | unset <key> |
    ren <key> <key> | commit | erase | show [--nosort|--nostat] |
    find <text> | defaults <--yes|--initcheck> | backup <filename> |
    restore <filename> [--test] [--force] [--forceall] [--nocommit] |
    export <--quote|--c|--set|--tab> [--nodefaults] |
    export <--dump|--dump0> | import [--forceall] <filename> |
    setfb64 <key> <filename> | getfb64 <key> <filename> |
    setfile <key> <filename> | getfile <key> <filename> | setfile2nvram <filename>
    root@gw:/tmp/home/root# exit
    root@gw:/tmp/home/root# exit
    Connection closed by foreign host.
    One reason I particularly like Entware is because it's package binaries are compiled sanely/correctly for a "secondary" environment (i.e. they do not rely pon anything in /lib -- that's by choice/design because not all firmwares are going to have the same versions of stuff in /lib). Entware properly uses -rpath during compile-time to set the preferred ld search path to /opt/lib, and has its own set of libc* et al libraries that it relies on. Proof of that:

    root@gw:/tmp/home/root# objdump -x /opt/bin/bash | egrep 'RPATH|NEEDED'
      NEEDED              libncurses.so.5
      NEEDED              libdl.so.0
      NEEDED              libgcc_s.so.1
      NEEDED              libc.so.0
      RPATH                /opt/lib
    root@gw:/tmp/home/root# ldd /opt/bin/bash
            libncurses.so.5 => /opt/lib/libncurses.so.5 (0x2aac0000)
            libdl.so.0 => /opt/lib/libdl.so.0 (0x2ab15000)
            libgcc_s.so.1 => /opt/lib/libgcc_s.so.1 (0x2ab28000)
            libc.so.0 => /opt/lib/libc.so.0 (0x2ab49000)
            ld-uClibc.so.0 => /opt/lib/ld-uClibc.so.0 (0x2aaa8000)
    root@gw:/tmp/home/root# opkg list-installed | egrep ^lib
    libbz2 - 1.0.6-1
    libc - 0.9.32-4
    libcurl - 7.29.0-1a
    libgcc - 4.6.3-4
    libidn - 1.18-1
    libmagic - 5.11-1
    libncurses - 5.9-1
    libopenssl - 1.0.1e-1
    libpcap - 1.3.0-1a
    libpcre - 8.11-2
    libpopt - 1.7-5
    libpthread - 0.9.32-4
    libreadline - 6.2-1
    librpc - 0.9.32-rc2-0a2179bbc0844928f2a0ec01dba93d9b5d6d41a7
    librt - 0.9.32-4
    librtmp - 2.4-20121209-1
    libstdcpp - 4.6.3-4
    libthread-db - 0.9.32-4
    So in short, this keeps everything completely segregated, thus ensures that Entware binaries will always work and libraries/etc. will never conflict with the "stock base firmware" libraries. It's done Correctly(tm), no LD_LIBRARY_PATH risky hackery needed or otherwise. I appreciate that fact.

    That's just my opinion though.

    Shibby absolutely has every right to choose what he adds/modifies in his firmware, and I fully support his right to choose (I sound like I'm talking about abortion or something, hahaha); nothing stops someone from downloading the Entware installation script, running it, and using it on his firmware. So it's all good as I see it.
    PeterFalk likes this.
  8. jerrm

    jerrm Network Guru Member

    Basically agree with both points above. Never had to go and "fix" bash on Entware, where it was required on Optware to have a usable system. Don't have issues with mc arrows, but maybe that's a terminal mapping/config issue.

    I will say there are occasional default config files on Entware that point to the wrong place. Seems like there were some issues with this on Optware as well, but it's been a while since I've done anything with Optware, so can't say for sure.

    Entware installs generally seemed to be noticeably smaller than Optware (good if using jffs) when I was comparing - but again it's been a while. Not where I can do a virgin install of either right now.

    Of course it's Shibby's call. I would like to see Entware get some love, but consider this a request, not a complaint.
  9. leandroong

    leandroong LI Guru Member

    I shifted to entware-optware when I cannot compile transmission.ipk due to outdated library. The problem is lack of library(s) upgrade. There are 2 repositories missing in entware that I would like to see, mainly "ncftp" and "plowshare". Hopefully, this will get added in the future.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice