lavv17 / lftp

sophisticated command line file transfer program (ftp, http, sftp, fish, torrent)
http://lftp.yar.ru
GNU General Public License v3.0
1.08k stars 159 forks source link

Unable to compile on Ubuntu 18.04 #619

Closed davehouser1 closed 3 years ago

davehouser1 commented 3 years ago

When trying to compile the latest version of lftp I get the following error when trying to build. Ubuntu 18.04

 lftp_tinfo.cc:40:3: error: #error No header file for tigetstr or tgetstr found. Install ncurses-dev or termcap-dev.
 # error No header file for tigetstr or tgetstr found. Install ncurses-dev or termcap-dev.
   ^~~~~
lftp_tinfo.cc: In function void init_terminfo():
lftp_tinfo.cc:55:7: error: setupterm was not declared in this scope
    if(setupterm(NULL, 1, &errret) == ERR)
       ^~~~~~~~~
lftp_tinfo.cc:55:38: error: ERR was not declared in this scope
    if(setupterm(NULL, 1, &errret) == ERR)
                                      ^~~
lftp_tinfo.cc: In function const char* get_string_term_cap(const char*, const char*):
lftp_tinfo.cc:73:22: error: tigetstr was not declared in this scope
    const char *ret = tigetstr(const_cast<char *>(terminfo_cap));
                      ^~~~~~~~
lftp_tinfo.cc:73:22: note: suggested alternative: getpt
    const char *ret = tigetstr(const_cast<char *>(terminfo_cap));
                      ^~~~~~~~
                      getpt
davehouser1 commented 3 years ago

Figure it out. This post https://github.com/lavv17/lftp/issues/58 sudo apt-get install ncurses-dev That fixed the issue.

The next issue was Make.in.in wanted "0.19" for GETTEXT_MACRO_VERSION. Then I needed to edit ./po/Make.in.in and change the macro version to "0.18"

Compiled after I did that.