tce-load -i compiletc readline-dev

cd inetutils-1.9.4

LIBS="-ltinfo" CC="gcc -flto -fuse-linker-plugin -mtune=generic -Os -pipe" CXX="g++ -flto -fuse-linker-plugin -mtune=generic -Os -pipe -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local --localstatedir=/var --libexecdir=/usr/local/lib/inetutils --disable-logger --disable-whois --disable-rcp --disable-rexec --disable-rlogin --disable-rsh

find . -name Makefile -type f -exec sed -i 's/-g -O2//g' {} \;

make
sudo make install

Summary of build decisions:

  Clients:

    dnsdomainname  yes
    ftp            yes  /usr/local/lib/libreadline.so -Wl,-rpath -Wl,/usr/local/lib
    hostname       yes
    ifconfig       yes
    logger         no
    ping           yes  
    ping6          yes  
    rcp            no
    rexec          no
    rlogin         no
    rsh            no
    talk           yes  -lcurses
    telnet         yes  
    tftp           yes
    traceroute     yes  
    whois          no

  Servers:

    ftpd           yes  
    inetd          yes
    rexecd         yes  
    rlogind        yes  
    rshd           yes  
    syslogd        yes
    talkd          yes
    telnetd        yes  
    tftpd          yes
    uucpd          yes

  Support:

    libls          yes