-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Source build of curl to enable proxy support for Pkg #17783
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,7 @@ include $(SRCDIR)/llvm-ver.make | |
# additionally all targets should be listed in the getall target for easier off-line compilation | ||
# if you are adding a new target, it can help to copy an similar, existing target | ||
# | ||
# autoconf configure-driven scripts: llvm pcre arpack fftw unwind gmp mpfr patchelf libuv | ||
# autoconf configure-driven scripts: llvm pcre arpack fftw unwind gmp mpfr patchelf libuv curl | ||
# custom Makefile rules: openlibm dsfmt suitesparse-wrapper suitesparse lapack openblas utf8proc objconv osxunwind | ||
# entirely custom: virtualenv | ||
# CMake libs: libgit2 libssh2 mbedtls | ||
|
@@ -171,8 +171,14 @@ ifeq ($(USE_SYSTEM_LIBSSH2), 0) | |
STAGE2_DEPS += libssh2 | ||
endif | ||
|
||
ifneq ($(OS), WINNT) | ||
ifeq ($(USE_SYSTEM_CURL), 0) | ||
STAGE3_DEPS += curl | ||
endif | ||
endif | ||
|
||
ifeq ($(USE_SYSTEM_LIBGIT2), 0) | ||
STAGE3_DEPS += libgit2 | ||
STAGE4_DEPS += libgit2 | ||
endif | ||
|
||
ifeq ($(USE_SYSTEM_MPFR), 0) | ||
|
@@ -211,7 +217,7 @@ endif | |
|
||
## Common build target prefixes | ||
|
||
DEP_LIBS := $(STAGE1_DEPS) $(STAGE2_DEPS) $(STAGE3_DEPS) | ||
DEP_LIBS := $(STAGE1_DEPS) $(STAGE2_DEPS) $(STAGE3_DEPS) $(STAGE4_DEPS) | ||
|
||
default: install | $(build_prefix) | ||
get: $(addprefix get-, $(DEP_LIBS)) | ||
|
@@ -222,7 +228,7 @@ install: $(addprefix install-, $(DEP_LIBS)) | |
cleanall: $(addprefix clean-, $(DEP_LIBS)) | ||
distcleanall: $(addprefix distclean-, $(DEP_LIBS)) | ||
rm -rf $(build_prefix) | ||
getall: get-llvm get-libuv get-pcre get-openlibm get-openspecfun get-dsfmt get-openblas get-lapack get-fftw get-suitesparse get-arpack get-unwind get-osxunwind get-gmp get-mpfr get-patchelf get-utf8proc get-virtualenv get-objconv get-mbedtls get-libssh2 get-libgit2 | ||
getall: get-llvm get-libuv get-pcre get-openlibm get-openspecfun get-dsfmt get-openblas get-lapack get-fftw get-suitesparse get-arpack get-unwind get-osxunwind get-gmp get-mpfr get-patchelf get-utf8proc get-virtualenv get-objconv get-mbedtls get-libssh2 get-curl get-libgit2 | ||
|
||
## PATHS ## | ||
# sort is used to remove potential duplicates | ||
|
@@ -271,6 +277,7 @@ include $(SRCDIR)/mpfr.mk | |
include $(SRCDIR)/patchelf.mk | ||
include $(SRCDIR)/mbedtls.mk | ||
include $(SRCDIR)/libssh2.mk | ||
include $(SRCDIR)/curl.mk | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should be done before libgit2, and libgit2 will need to declare a dependency on it There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good point. I will move it above. libgit2 and curl are in different build stages. Shouldn't that be good enough? I do think that libssh2 should probably be stage 1 (currently in 2), curl in stage 2 and libgit2 in stage 3. |
||
include $(SRCDIR)/libgit2.mk | ||
include $(SRCDIR)/virtualenv.mk | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,3 +13,4 @@ MPFR_VER = 3.1.4 | |
PATCHELF_VER = 0.9 | ||
VIRTUALENV_VER = 15.0.0 | ||
MBEDTLS_VER = 2.3.0 | ||
CURL_VER = 7.50.1 |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
015f6a0217ca6f2c5442ca406476920b |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
94acd91fcf8ff2605e1ba2d086c2c366257b61eaf516b9ea44e574e315feb5b30f6e47d89051f259e026ef5dd9edde5f7b15a6af9ee6a38f641da354e1e677b1 |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
## CURL ## | ||
|
||
CURL_SRC_TARGET := $(BUILDDIR)/curl-$(CURL_VER)/.libs/libcurl.$(SHLIB_EXT) | ||
CURL_OBJ_TARGET := $(build_shlibdir)/libcurl.$(SHLIB_EXT) | ||
|
||
ifneq ($(OS),WINNT) | ||
CURL_LDFLAGS := $(RPATH_ESCAPED_ORIGIN) | ||
endif | ||
|
||
$(SRCDIR)/srccache/curl-$(CURL_VER).tar.bz2: | $(SRCDIR)/srccache | ||
$(JLDOWNLOAD) $@ https://curl.haxx.se/download/curl-$(CURL_VER).tar.bz2 | ||
$(SRCDIR)/srccache/curl-$(CURL_VER)/configure: $(SRCDIR)/srccache/curl-$(CURL_VER).tar.bz2 $(MBEDTLS_OBJ_TARGET) $(LIBSSH2_OBJ_TARGET) | ||
$(JLCHECKSUM) $< | ||
cd $(dir $<) && $(TAR) jxf $(notdir $<) | ||
touch -c $@ | ||
$(BUILDDIR)/curl-$(CURL_VER)/config.status: $(SRCDIR)/srccache/curl-$(CURL_VER)/configure | ||
mkdir -p $(dir $@) | ||
cd $(dir $@) && \ | ||
$< $(CONFIGURE_COMMON) --includedir=$(build_includedir) --with-mbedtls=$(build_shlibdir)/.. CFLAGS="$(CFLAGS) $(CURL_CFLAGS)" LDFLAGS="$(LDFLAGS) $(CURL_LDFLAGS)" | ||
touch -c $@ | ||
$(CURL_SRC_TARGET): $(BUILDDIR)/curl-$(CURL_VER)/config.status | ||
$(MAKE) -C $(dir $<) $(LIBTOOL_CCLD) | ||
touch -c $@ | ||
$(BUILDDIR)/curl-$(CURL_VER)/checked: $(CURL_SRC_TARGET) | ||
ifeq ($(OS),$(BUILD_OS)) | ||
ifneq ($(OS),WINNT) | ||
$(MAKE) -C $(dir $@) check -j1 | ||
endif | ||
endif | ||
echo 1 > $@ | ||
$(CURL_OBJ_TARGET): $(CURL_SRC_TARGET) | ||
$(call make-install,curl-$(CURL_VER),$(LIBTOOL_CCLD)) | ||
$(INSTALL_NAME_CMD)libcurl.$(SHLIB_EXT) $@ | ||
touch -c $@ | ||
|
||
clean-curl: | ||
-$(MAKE) -C $(BUILDDIR)/curl-$(CURL_VER) clean | ||
-rm -f $(build_shlibdir)/libcurl* | ||
distclean-curl: | ||
-rm -rf $(SRCDIR)/srccache/curl-$(CURL_VER).tar.bz2 $(SRCDIR)/srccache/curl-$(CURL_VER) $(BUILDDIR)/curl-$(CURL_VER) | ||
|
||
get-curl: $(SRCDIR)/srccache/curl-$(CURL_VER).tar.bz2 | ||
configure-curl: $(BUILDDIR)/curl-$(CURL_VER)/config.status | ||
compile-curl: $(CURL_SRC_TARGET) | ||
check-curl: $(BUILDDIR)/curl-$(CURL_VER)/checked | ||
install-curl: $(CURL_OBJ_TARGET) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- ssl.h.old 2016-06-28 18:12:06.000000000 +0530 | ||
+++ ssl.h 2016-08-03 18:51:34.000000000 +0530 | ||
@@ -54,7 +54,8 @@ | ||
#endif | ||
|
||
#if defined(MBEDTLS_HAVE_TIME) | ||
-#include <time.h> | ||
+//#include <time.h> | ||
+#include "platform.h" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. strange - cmake should be doing the configure probes for this, what were you seeing without this patch? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is a known bug fixed upstream, and hopefully should be in mbedtls 2.3.1. Maybe mac only, but the fix should work everywhere (I think). |
||
#endif | ||
|
||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also needed for the makefile dependencies, this isn't enough
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Elaborate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since the makefile dependencies are not conditional on OS, this ifeq won't prevent curl from building on windows
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated libgit2.mk.