Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Curl compilation failed on LIBSSH2_SFTP_STATVFS' undeclared #831

Closed
Bramzor opened this issue May 27, 2016 · 6 comments
Closed

Curl compilation failed on LIBSSH2_SFTP_STATVFS' undeclared #831

Bramzor opened this issue May 27, 2016 · 6 comments

Comments

@Bramzor
Copy link

Bramzor commented May 27, 2016

I did this

Trying to compile the new version of Curl (curl-7.49.0.tar.gz) to update my current verions:
curl -V
curl 7.47.1

I expected the following

Compilation of this is done automatically via custombuild from DirectAdmin, this is actually the first time that it fails.

curl/libcurl version

[curl -V output perhaps?]
Curl that I'm trying to compile is curl-7.49
LibSSH2 version 1.2.9-1.el5.rf

operating system

CloudLinux Server release 5.11

error:

CC libcurl_la-ssh.lo
ssh.c: In function 'ssh_statemach_act':
ssh.c:1624: error: 'LIBSSH2_SFTP_STATVFS' undeclared (first use in this function)
ssh.c:1624: error: (Each undeclared identifier is reported only once
ssh.c:1624: error: for each function it appears in.)
ssh.c:1624: error: expected ';' before 'statvfs'
ssh.c:1627: error: 'statvfs' undeclared (first use in this function)
make[2]: *** [libcurl_la-ssh.lo] Error 1
make[2]: Leaving directory /usr/local/directadmin/custombuild/curl-7.49.0/lib' make[1]: *** [all] Error 2 make[1]: Leaving directory/usr/local/directadmin/custombuild/curl-7.49.0/lib'
make: *** [all-recursive] Error 1

@jay
Copy link
Member

jay commented May 28, 2016

LIBSSH2_SFTP_STATVFS was added 6 years ago to libssh2 1.2.6. If we want to allow earlier versions of libssh2 we could do something like

#ifdef LIBSSH2_SFTP_ST_RDONLY
#define HAVE_LIBSSH2_SFTP_STATVFS
#endif

and then guard the statvfs sections with HAVE_LIBSSH2_SFTP_STATVFS. I don't think that will help here though, if you're using 1.2.9. Are you sure about that?

@jay jay added the build label May 28, 2016
@bagder
Copy link
Member

bagder commented May 28, 2016

I think we should either make libcurl build with that old libssh2 version or we should check for it and tell the user that it is too old to work...

@Bramzor
Copy link
Author

Bramzor commented May 28, 2016

I assume the version I use is the one that is installed. No way to get the version of the library?
Installed Packages Name : libssh2 Arch : x86_64 Version : 1.2.9 Release : 1.el5.rf Size : 830 k Repo : installed Summary : Library implementing the SSH2 protocol URL : http://www.libssh2.org/ License : BSD Description: libssh2 is a library implementing the SSH2 protocol as defined by : Internet Drafts: SECSH-TRANS(22), SECSH-USERAUTH(25), : SECSH-CONNECTION(23), SECSH-ARCH(20), SECSH-FILEXFER(06)*, : SECSH-DHGEX(04), and SECSH-NUMBERS(10).

Is that an old version? It's the one in the repository.

@bagder
Copy link
Member

bagder commented May 28, 2016

libssh2 1.2.9 is soon five years old and there have been a bunch of releases since then. 1.7.0 is the latest these days.

@Bramzor
Copy link
Author

Bramzor commented May 28, 2016

No newer version in the most used repo's of EL5. Still one year before it's EOL.
Could I use alt-libssh2?

Available Packages Name : alt-libssh2 Arch : x86_64 Version : 1.4.3 Release : 8.el5 Size : 130 k Repo : cloudlinux-x86_64-server-5 Summary : A library implementing the SSH2 protocol License : BSD Description: libssh2 is a library implementing the SSH2 protocol as defined by : Internet Drafts: SECSH-TRANS(22), SECSH-USERAUTH(25), : SECSH-CONNECTION(23), SECSH-ARCH(20), SECSH-FILEXFER(06)*, : SECSH-DHGEX(04), and SECSH-NUMBERS(10).

@jay
Copy link
Member

jay commented May 28, 2016

I don't see why not. No matter which of those you use it should work though. Is it possible you have an older libssh2 installed somewhere?

@bagder bagder closed this as completed in e51798d May 28, 2016
@lock lock bot locked as resolved and limited conversation to collaborators May 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

No branches or pull requests

3 participants