git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / Atom feed
* [GSOC] fatal error: curl/curl.h: No such file or directory
@ 2021-02-20 13:57 Divyansh Garg
  2021-02-20 14:11 ` Torsten Bögershausen
  2021-02-20 19:07 ` SZEDER Gábor
  0 siblings, 2 replies; 3+ messages in thread
From: Divyansh Garg @ 2021-02-20 13:57 UTC (permalink / raw)
  To: git

Hello,
I am trying to build the source code on my system (Ubuntu 20.04).
After cloning the repo, when I proceed with the command: make, I get
the following error.
I tried installing curl and searched the internet but couldn't get a fix.
Please advise, how can I solve this problem.

divyansh:~/gsoc/git$ make
make: curl-config: Command not found
    * new prefix flags
    CC attr.o
    CC config.o
    CC exec-cmd.o
    CC gettext.o
    AR libgit.a
    LINK git-daemon
    LINK git-http-backend
    LINK git-imap-send
    LINK git-sh-i18n--envsubst
    LINK git-shell
    CC http.o
In file included from http.c:2:
http.h:6:10: fatal error: curl/curl.h: No such file or directory
    6 | #include <curl/curl.h>
      |          ^~~~~~~~~~~~~
compilation terminated.
make: *** [Makefile:2422: http.o] Error 1



Divyansh Garg

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [GSOC] fatal error: curl/curl.h: No such file or directory
  2021-02-20 13:57 [GSOC] fatal error: curl/curl.h: No such file or directory Divyansh Garg
@ 2021-02-20 14:11 ` Torsten Bögershausen
  2021-02-20 19:07 ` SZEDER Gábor
  1 sibling, 0 replies; 3+ messages in thread
From: Torsten Bögershausen @ 2021-02-20 14:11 UTC (permalink / raw)
  To: Divyansh Garg; +Cc: git

On Sat, Feb 20, 2021 at 07:27:32PM +0530, Divyansh Garg wrote:
> Hello,
> I am trying to build the source code on my system (Ubuntu 20.04).
> After cloning the repo, when I proceed with the command: make, I get
> the following error.
> I tried installing curl and searched the internet but couldn't get a fix.
> Please advise, how can I solve this problem.

Welcome to the Git community.
You need to install the development package of some packages,
which come with header files (and not only the libs).

Being a lazy person, I collected all possible package names in a setupscript,
looking similar to this:
  APTGET="sudo apt-get install"
 type curl-config || $APTGET libcurl4-openssl-dev || $APTGET libcurl-devel
 test -r /usr/include/expat.h || $APTGET libexpat1-dev || $APTGET expat-devel || $APTGET libexpat-devel
 test -r /usr/include/ssl.h || test -r /usr/include/openssl/ssl.h || $APTGET openssl-devel || $APTGET  libssl-dev
 test -r /usr/include/zlib.h || $APTGET zlib1g-dev
 type msgfmt || $APTGET gettext

In other words,
sudo apt-get install libcurl-devel
could help.
And you probably need to install more dev/devel packages, unfortunatly different Linux distros
use different names for (from a user point of view) the same thing.
So I can't tell you out of my head, what Ubuntu needs, but there is hopefully a start point.

[snip]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [GSOC] fatal error: curl/curl.h: No such file or directory
  2021-02-20 13:57 [GSOC] fatal error: curl/curl.h: No such file or directory Divyansh Garg
  2021-02-20 14:11 ` Torsten Bögershausen
@ 2021-02-20 19:07 ` SZEDER Gábor
  1 sibling, 0 replies; 3+ messages in thread
From: SZEDER Gábor @ 2021-02-20 19:07 UTC (permalink / raw)
  To: Divyansh Garg; +Cc: git

On Sat, Feb 20, 2021 at 07:27:32PM +0530, Divyansh Garg wrote:
> Hello,
> I am trying to build the source code on my system (Ubuntu 20.04).
> After cloning the repo, when I proceed with the command: make, I get
> the following error.
> I tried installing curl and searched the internet but couldn't get a fix.
> Please advise, how can I solve this problem.
> 
> divyansh:~/gsoc/git$ make
> make: curl-config: Command not found
>     * new prefix flags
>     CC attr.o
>     CC config.o
>     CC exec-cmd.o
>     CC gettext.o
>     AR libgit.a
>     LINK git-daemon
>     LINK git-http-backend
>     LINK git-imap-send
>     LINK git-sh-i18n--envsubst
>     LINK git-shell
>     CC http.o
> In file included from http.c:2:
> http.h:6:10: fatal error: curl/curl.h: No such file or directory
>     6 | #include <curl/curl.h>
>       |          ^~~~~~~~~~~~~
> compilation terminated.
> make: *** [Makefile:2422: http.o] Error 1

As Torsten said you have to install not only a couple of libraries but
also the related '-dev' package containing includes and static
libraries.

In our CI jobs using Ubuntu we install the following packages by
default (see 'ci/install-dependencies.sh'):

UBUNTU_COMMON_PKGS="make libssl-dev libcurl4-openssl-dev libexpat-dev
 tcl tk gettext zlib1g-dev perl-modules liberror-perl libauthen-sasl-perl
 libemail-valid-perl libio-socket-ssl-perl libnet-smtp-ssl-perl"


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-02-20 19:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-20 13:57 [GSOC] fatal error: curl/curl.h: No such file or directory Divyansh Garg
2021-02-20 14:11 ` Torsten Bögershausen
2021-02-20 19:07 ` SZEDER Gábor

git@vger.kernel.org list mirror (unofficial, one of many)

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://public-inbox.org/git
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 git git/ https://public-inbox.org/git \
		git@vger.kernel.org
	public-inbox-index git

Example config snippet for mirrors.
Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.version-control.git
	nntp://ou63pmih66umazou.onion/inbox.comp.version-control.git
	nntp://czquwvybam4bgbro.onion/inbox.comp.version-control.git
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.version-control.git
	nntp://news.gmane.io/gmane.comp.version-control.git
 note: .onion URLs require Tor: https://www.torproject.org/

code repositories for the project(s) associated with this inbox:

	https://80x24.org/mirrors/git.git

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git