[APP] Compiled lynx binary for android - Shell or ADB

Search This thread

Moronig

Senior Member
Dec 2, 2010
419
206
Curitiba
I've searched the web, and found no lynx binaries for android, so I set out to compile it myself.

For the uninitiated, lynx is a text-based browser. No images, no javascript, no flash. Just pure content.
You can use it by connecting to your phone through adb, telnet, ssh or a shell on the phone itself.

lynx4.png


This is lynx version 2.8.8 with ncurses 5.9

I pretty much just followed the instructions at http://www.embedu.org/Column/Column294.htm, and added a flag to make the linking static. No code changes were required.

Installation instructions

Root is not required.

You need to unzip the file on the /sdcard folder. The following files must exist:

/sdcard/lynx/lynx.cfg
/sdcard/lynx/lynx.lss
/sdcard/lynx/cache/

Then you need to move the binary to /data/local (or /system/xbin if you want something more permanent. Then you'd need root)
and run this command:
chmod 755 /data/local/lynx

Then run :

/data/local/lynx

and enjoy!

Additional information

If you want to put these files somewhere else, you must redefine the following variables, respectively:

LYNX_CFG (eg: export LYNX_CFG=/system/etc/lynx.cfg)
LYNX_LSS (eg: export LYNX_LSS =/system/etc/lynx.lss)
TMPDIR (eg: export TMPDIR =/cache)


If you receive an error message about the terminal, you need to configure a terminal.
Here are some instruction (for nano, but it works the same)

Sources are at the following addresses:
http://lynx.browser.org/
http://www.gnu.org/s/ncurses/
 

Attachments

  • lynx.zip
    1 MB · Views: 4,283
Awesome

Will be testing on my thunderbolt later today. I'll let you guys know how it goes.

However, would you mind reposting this on RW, or would you mind if I were to repost it and link back?

[EDIT] In having just configured everything, I also get the error from the post above. It seems as though lynx thinks it doesn't have internet access. This is the case on 3g and wireless networks. Let me know if you want me to test anything for you.[/EDIT]

All the best,

-HG
 
Last edited:

Gusar321

Senior Member
May 5, 2011
404
71
While this is quite cool, why lynx? Why not elinks? It has much better layout capabilities. It has tabs! It even has javascript.
 

dangpzanco

Senior Member
Dec 27, 2010
717
87
LG Nexus 5X
Samsung Galaxy Tab E
Code:
root@localhost:/# apt-get install lynx
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
  lynx
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/215kB of archives.
After this operation, 254kB of additional disk space will be used.
Selecting previously deselected package lynx.
(Reading database ... 66275 files and directories currently installed.)
Unpacking lynx (from .../lynx_2.8.8dev.2-1_all.deb) ...

I installed it that way.
Search for opkg (i think this is the name) if you are curious. It's a way of using deb packaging on Android (G1), but not in development anymore...

Sent from my Milestone 2 XDA App
 
Last edited:
  • Like
Reactions: hacktivismo

alelrawy

New member
Jul 13, 2016
1
0
I am getting the following error

Looking up <url>.
Unable to locate remote host <url>
Alert!: Unable to connect to remote host.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 7
    I've searched the web, and found no lynx binaries for android, so I set out to compile it myself.

    For the uninitiated, lynx is a text-based browser. No images, no javascript, no flash. Just pure content.
    You can use it by connecting to your phone through adb, telnet, ssh or a shell on the phone itself.

    lynx4.png


    This is lynx version 2.8.8 with ncurses 5.9

    I pretty much just followed the instructions at http://www.embedu.org/Column/Column294.htm, and added a flag to make the linking static. No code changes were required.

    Installation instructions

    Root is not required.

    You need to unzip the file on the /sdcard folder. The following files must exist:

    /sdcard/lynx/lynx.cfg
    /sdcard/lynx/lynx.lss
    /sdcard/lynx/cache/

    Then you need to move the binary to /data/local (or /system/xbin if you want something more permanent. Then you'd need root)
    and run this command:
    chmod 755 /data/local/lynx

    Then run :

    /data/local/lynx

    and enjoy!

    Additional information

    If you want to put these files somewhere else, you must redefine the following variables, respectively:

    LYNX_CFG (eg: export LYNX_CFG=/system/etc/lynx.cfg)
    LYNX_LSS (eg: export LYNX_LSS =/system/etc/lynx.lss)
    TMPDIR (eg: export TMPDIR =/cache)


    If you receive an error message about the terminal, you need to configure a terminal.
    Here are some instruction (for nano, but it works the same)

    Sources are at the following addresses:
    http://lynx.browser.org/
    http://www.gnu.org/s/ncurses/
    1
    Code:
    root@localhost:/# apt-get install lynx
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    The following NEW packages will be installed:
      lynx
    0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
    Need to get 0B/215kB of archives.
    After this operation, 254kB of additional disk space will be used.
    Selecting previously deselected package lynx.
    (Reading database ... 66275 files and directories currently installed.)
    Unpacking lynx (from .../lynx_2.8.8dev.2-1_all.deb) ...

    I installed it that way.
    Search for opkg (i think this is the name) if you are curious. It's a way of using deb packaging on Android (G1), but not in development anymore...

    Sent from my Milestone 2 XDA App