Permalink
Browse files

includes: remove curl/curlbuild.h and curl/curlrules.h

Rely entirely on curl/system.h now.

Introduced in Aug 2008 with commit 14240e9. Now gone.

Fixes #1456
  • Loading branch information...
bagder committed May 22, 2017
1 parent 54b636f commit 73a2fcea0b4adea6ba342cd7ed1149782c214ae3
View
@@ -5,7 +5,7 @@
# | (__| |_| | _ <| |___
# \___|\___/|_| \_\_____|
#
# Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
# Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
#
# This software is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
@@ -1111,7 +1111,7 @@ else()
set(CURL_SIZEOF_CURL_SOCKLEN_T ${SIZEOF_INT})
endif()
# TODO test which of these headers are required for the typedefs used in curlbuild.h
# TODO test which of these headers are required
if(WIN32)
set(CURL_PULL_WS2TCPIP_H ${HAVE_WS2TCPIP_H})
else()
@@ -1297,16 +1297,10 @@ if(NOT CURL_CONFIG_HAS_BEEN_RUN_BEFORE)
set(CURL_CONFIG_HAS_BEEN_RUN_BEFORE 1 CACHE INTERNAL "Flag to track whether this is the first time running CMake or if CMake has been configured before")
endif()
# Installation.
# First, install generated curlbuild.h
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/include/curl/curlbuild.h"
DESTINATION include/curl )
# Next, install other headers excluding curlbuild.h
# install headers
install(DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/include/curl"
DESTINATION include
FILES_MATCHING PATTERN "*.h"
PATTERN "curlbuild.h" EXCLUDE)
FILES_MATCHING PATTERN "*.h")
# Workaround for MSVS10 to avoid the Dialog Hell
# FIXME: This could be removed with future version of CMake.
View
@@ -126,15 +126,6 @@ if test ! -z $SDK32; then
pwd
lipo libcurl.framework/${FRAMEWORK_VERSION}/libcurl32 libcurl.framework/${FRAMEWORK_VERSION}/libcurl64 -create -output libcurl.framework/${FRAMEWORK_VERSION}/libcurl
rm libcurl.framework/${FRAMEWORK_VERSION}/libcurl32 libcurl.framework/${FRAMEWORK_VERSION}/libcurl64
cp libcurl.framework/${FRAMEWORK_VERSION}/Headers/curl/curlbuild.h libcurl.framework/${FRAMEWORK_VERSION}/Headers/curl/curlbuild32.h
cp include/curl/curlbuild.h libcurl.framework/${FRAMEWORK_VERSION}/Headers/curl/curlbuild64.h
cat >libcurl.framework/${FRAMEWORK_VERSION}/Headers/curl/curlbuild.h <<EOF
#ifdef __LP64__
#include "curl/curlbuild64.h"
#else
#include "curl/curlbuild32.h"
#endif
EOF
fi
pwd
View
@@ -27,7 +27,7 @@ ACLOCAL_AMFLAGS = -I m4
CMAKE_DIST = CMakeLists.txt CMake/CMakeConfigurableFile.in \
CMake/CurlTests.c CMake/FindGSS.cmake CMake/OtherTests.cmake \
CMake/Platforms/WindowsCache.cmake CMake/Utilities.cmake \
include/curl/curlbuild.h.cmake CMake/Macros.cmake \
CMake/Macros.cmake \
CMake/CurlSymbolHiding.cmake CMake/FindCARES.cmake \
CMake/FindLibSSH2.cmake CMake/FindNGHTTP2.cmake \
CMake/FindMbedTLS.cmake
View
@@ -5,7 +5,7 @@
# | (__| |_| | _ <| |___
# \___|\___/|_| \_\_____|
#
# Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
# Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
#
# This software is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
@@ -2079,10 +2079,7 @@ _EOF
dnl CURL_CONFIGURE_LONG
dnl -------------------------------------------------
dnl Find out the size of long as reported by sizeof() and define
dnl CURL_SIZEOF_LONG as appropriate to be used in template file
dnl include/curl/curlbuild.h.in to properly configure the library.
dnl The size of long is a build time characteristic and as such
dnl must be recorded in curlbuild.h
dnl CURL_SIZEOF_LONG.
AC_DEFUN([CURL_CONFIGURE_LONG], [
if test -z "$ac_cv_sizeof_long" ||
@@ -2095,10 +2092,6 @@ AC_DEFUN([CURL_CONFIGURE_LONG], [
dnl CURL_CONFIGURE_CURL_SOCKLEN_T
dnl -------------------------------------------------
dnl Find out suitable curl_socklen_t data type definition and size, making
dnl appropriate definitions for template file include/curl/curlbuild.h.in
dnl to properly configure and use the library.
dnl
dnl The need for the curl_socklen_t definition arises mainly to properly
dnl interface HP-UX systems which on one hand have a typedef'ed socklen_t
dnl data type which is 32 or 64-Bit wide depending on the data model being
@@ -2222,10 +2215,6 @@ AC_DEFUN([CURL_CONFIGURE_CURL_SOCKLEN_T], [
dnl CURL_CONFIGURE_PULL_SYS_POLL
dnl -------------------------------------------------
dnl Find out if system header file sys/poll.h must be included by the
dnl external interface, making appropriate definitions for template file
dnl include/curl/curlbuild.h.in to properly configure and use the library.
dnl
dnl The need for the sys/poll.h inclusion arises mainly to properly
dnl interface AIX systems which define macros 'events' and 'revents'.
@@ -2859,8 +2848,7 @@ AC_DEFUN([DO_CURL_OFF_T_SUFFIX_CHECK], [
dnl CURL_CONFIGURE_CURL_OFF_T
dnl -------------------------------------------------
dnl Find out suitable curl_off_t data type definition and associated
dnl items, and make the appropriate definitions used in template file
dnl include/curl/curlbuild.h.in to properly configure the library.
dnl items
AC_DEFUN([CURL_CONFIGURE_CURL_OFF_T], [
AC_REQUIRE([CURL_INCLUDES_INTTYPES])dnl
View
@@ -306,7 +306,6 @@ for fname in .deps \
configure \
configurehelp.pm \
curl-config \
curlbuild.h \
depcomp \
libcares.pc \
libcurl.pc \
View
@@ -6,7 +6,7 @@ rem * / __| | | | |_) | |
rem * | (__| |_| | _ <| |___
rem * \___|\___/|_| \_\_____|
rem *
rem * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
rem * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
rem *
rem * This software is licensed as described in the file COPYING, which
rem * you should have received as part of this distribution. The terms
@@ -73,7 +73,6 @@ rem
echo Generating prerequisite files
call :generate
if errorlevel 4 goto nogencurlbuild
if errorlevel 3 goto nogenhugehelp
if errorlevel 2 goto nogenmakefile
if errorlevel 1 goto warning
@@ -83,7 +82,6 @@ rem
echo Removing prerequisite files
call :clean
if errorlevel 3 goto nocleancurlbuild
if errorlevel 2 goto nocleanhugehelp
if errorlevel 1 goto nocleanmakefile
)
@@ -98,7 +96,6 @@ rem 0 - success
rem 1 - success with simplified tool_hugehelp.c
rem 2 - failed to generate Makefile
rem 3 - failed to generate tool_hugehelp.c
rem 4 - failed to generate curlbuild.h
rem
:generate
if "%OS%" == "Windows_NT" setlocal
@@ -126,16 +123,6 @@ rem
)
cmd /c exit 0
rem Create curlbuild.h
echo * %CD%\include\curl\curlbuild.h
if exist include\curl\curlbuild.h.dist (
copy /Y include\curl\curlbuild.h.dist include\curl\curlbuild.h 1>NUL 2>&1
if errorlevel 1 (
if "%OS%" == "Windows_NT" endlocal
exit /B 4
)
)
rem Setup c-ares git tree
if exist ares\buildconf.bat (
echo.
@@ -160,7 +147,6 @@ rem
rem 0 - success
rem 1 - failed to clean Makefile
rem 2 - failed to clean tool_hugehelp.c
rem 3 - failed to clean curlbuild.h
rem
:clean
rem Remove Makefile
@@ -181,15 +167,6 @@ rem
)
)
rem Remove curlbuild.h
echo * %CD%\include\curl\curlbuild.h
if exist include\curl\curlbuild.h (
del include\curl\curlbuild.h 2>NUL
if exist include\curl\curlbuild.h (
exit /B 3
)
)
exit /B
rem Function to generate src\tool_hugehelp.c
@@ -304,11 +281,6 @@ rem
echo Error: Unable to generate src\tool_hugehelp.c
goto error
:nogencurlbuild
echo.
echo Error: Unable to generate include\curl\curlbuild.h
goto error
:nocleanmakefile
echo.
echo Error: Unable to clean Makefile
@@ -319,11 +291,6 @@ rem
echo Error: Unable to clean src\tool_hugehelp.c
goto error
:nocleancurlbuild
echo.
echo Error: Unable to clean include\curl\curlbuild.h
goto error
:warning
echo.
echo Warning: The curl manual could not be integrated in the source. This means when
View
@@ -36,7 +36,7 @@ This configure script may be copied, distributed and modified under the
terms of the curl license; see COPYING for more details])
AC_CONFIG_SRCDIR([lib/urldata.h])
AC_CONFIG_HEADERS(lib/curl_config.h include/curl/curlbuild.h)
AC_CONFIG_HEADERS(lib/curl_config.h)
AC_CONFIG_MACRO_DIR([m4])
AM_MAINTAINER_MODE
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
@@ -121,11 +121,6 @@ AC_SUBST([AR])
AC_SUBST(libext)
dnl Remove non-configure distributed curlbuild.h
if test -f ${srcdir}/include/curl/curlbuild.h; then
rm -f ${srcdir}/include/curl/curlbuild.h
fi
dnl figure out the libcurl version
CURLVERSION=`$SED -ne 's/^#define LIBCURL_VERSION "\(.*\)".*/\1/p' ${srcdir}/include/curl/curlver.h`
XC_CHECK_PROG_CC
View
@@ -30,7 +30,6 @@ FAQ
2.2 Does curl work/build with other SSL libraries?
2.3 Where can I find a copy of LIBEAY32.DLL?
2.4 Does curl support SOCKS (RFC 1928) ?
2.5 Install libcurl for both 32bit and 64bit?
3. Usage Problems
3.1 curl: (1) SSL is disabled, https: not supported
@@ -466,32 +465,6 @@ FAQ
Yes, SOCKS 4 and 5 are supported.
2.5 Install libcurl for both 32bit and 64bit?
In curl's configure procedure one of the regular include files gets created
with platform specific information. The file 'curl/curlbuild.h' in the
installed libcurl file tree is therefore somewhat tied to that particular
platform.
To allow applications to get built for either 32bit or 64bit you need to
install libcurl headers for both setups and unfortunately curl doesn't do
this automatically.
A commonly used procedure is this:
$ ./configure [32bit platform]
$ mv curl/curlbuild.h curl/curlbuild-32bit.h
$ ./configure [64bit platform]
$ mv curl/curlbuild.h curl/curlbuild-64bit.h
Then you make a toplevel curl/curlbuild.h replacement that only does this:
#ifdef IS_32BIT
#include "curlbuild-32bit.h"
else
#include "curlbuild-64bit.h"
#endif
3. Usage problems
View
@@ -37,17 +37,6 @@ Current flaws in the curl CMake build
- Does't detect the correct strerror_r flavor when cross-compiling (issue #1123)
Important notice
==================
If you got your curl sources from a distribution tarball, make sure to
delete the generic 'include/curl/curlbuild.h' file that comes with it:
rm -f curl/include/curl/curlbuild.h
The purpose of this file is to provide reasonable definitions for systems
where autoconfiguration is not available. CMake will create its own
version of this file in its build directory. If the "generic" version
is not deleted, weird build errors may occur on some systems.
Command Line CMake
==================
A CMake build of curl is similar to the autotools build of curl. It
@@ -5,7 +5,7 @@
# | (__| |_| | _ <| |___
# \___|\___/|_| \_\_____|
#
# Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
# Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
#
# This software is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
@@ -30,13 +30,9 @@ EXTRA_DIST = README Makefile.example Makefile.inc Makefile.m32 \
# being currently built and tested are searched before the library which
# might possibly already be installed in the system.
#
# $(top_builddir)/include/curl for generated curlbuild.h included from curl.h
# $(top_builddir)/include for generated curlbuild.h inc. from lib/curl_setup.h
# $(top_srcdir)/include is for libcurl's external include files
AM_CPPFLAGS = -I$(top_builddir)/include/curl \
-I$(top_builddir)/include \
-I$(top_srcdir)/include
AM_CPPFLAGS = -I$(top_srcdir)/include
LIBDIR = $(top_builddir)/lib
View
@@ -16,31 +16,9 @@ curl subdirectory. It makes it more likely to survive future modifications.
NOTE FOR LIBCURL HACKERS
The following notes apply to libcurl version 7.19.0 and later.
* The distributed curl/curlbuild.h file is only intended to be used on systems
which can not run the also distributed configure script.
* The distributed curlbuild.h file is generated as a copy of curlbuild.h.dist
when the libcurl source code distribution archive file is originally created.
* If you check out from git on a non-configure platform, you must run the
appropriate buildconf* script to set up curlbuild.h and other local files
before being able of compiling the library.
* On systems capable of running the configure script, the configure process
will overwrite the distributed include/curl/curlbuild.h file with one that
is suitable and specific to the library being configured and built, which
is generated from the include/curl/curlbuild.h.in template file.
* If you intend to distribute an already compiled libcurl library you _MUST_
also distribute along with it the generated curl/curlbuild.h which has been
used to compile it. Otherwise the library will be of no use for the users of
the library that you have built. It is _your_ responsibility to provide this
file. No one at the curl project can know how you have built the library.
* File curl/curlbuild.h includes platform and configuration dependent info,
and must not be modified by anyone. Configure script generates it for you.
appropriate buildconf* script to set up files before being able of compiling
the library.
* We cannot assume anything else but very basic compiler features being
present. While libcurl requires an ANSI C compiler to build, some of the
View
@@ -1,4 +1,3 @@
curlbuild.h
curlver.h.dist
stamp-h2
stamp-h3
View
@@ -21,31 +21,12 @@
###########################################################################
pkginclude_HEADERS = \
curl.h curlver.h easy.h mprintf.h stdcheaders.h multi.h \
typecheck-gcc.h curlbuild.h curlrules.h system.h
typecheck-gcc.h system.h
pkgincludedir= $(includedir)/curl
# curlbuild.h does not exist in the git tree. When the original libcurl
# source code distribution archive file is created, curlbuild.h.dist is
# renamed to curlbuild.h and included in the tarball so that it can be
# used directly on non-configure systems.
#
# The distributed curlbuild.h will be overwritten on configure systems
# when the configure script runs, with one that is suitable and specific
# to the library being configured and built.
#
# curlbuild.h.in is the distributed template file from which the configure
# script creates curlbuild.h at library configuration time, overwiting the
# one included in the distribution archive.
#
# curlbuild.h.dist is not included in the source code distribution archive.
EXTRA_DIST = curlbuild.h.in
DISTCLEANFILES = curlbuild.h
checksrc:
@@PERL@ $(top_srcdir)/lib/checksrc.pl -Wcurlbuild.h -D$(top_srcdir)/include/curl $(pkginclude_HEADERS) $(EXTRA_DIST)
@@PERL@ $(top_srcdir)/lib/checksrc.pl -D$(top_srcdir)/include/curl $(pkginclude_HEADERS)
if CURLDEBUG
# for debug builds, we scan the sources on all regular make invokes
Oops, something went wrong.

5 comments on commit 73a2fce

@gvanem

This comment has been minimized.

Show comment
Hide comment
@gvanem

gvanem Jun 20, 2017

Member

Not sure if it was this change that broke the djgpp build. But it's an easy fix:

--- a/lib/makefile.dj 2017-06-20 17:48:02
+++ b/lib/makefile.dj 2017-06-20 18:11:42
@@ -26,12 +26,14 @@
 #

 DEPEND_PREREQ = curl_config.h
-VPATH  = vtls
+VPATH  = vtls vauth
 TOPDIR = ..

 include ../packages/DOS/common.dj
 include Makefile.inc

+CFLAGS += -DBUILDING_LIBCURL
+
 SOURCES = $(sort $(CSOURCES))
Member

gvanem replied Jun 20, 2017

Not sure if it was this change that broke the djgpp build. But it's an easy fix:

--- a/lib/makefile.dj 2017-06-20 17:48:02
+++ b/lib/makefile.dj 2017-06-20 18:11:42
@@ -26,12 +26,14 @@
 #

 DEPEND_PREREQ = curl_config.h
-VPATH  = vtls
+VPATH  = vtls vauth
 TOPDIR = ..

 include ../packages/DOS/common.dj
 include Makefile.inc

+CFLAGS += -DBUILDING_LIBCURL
+
 SOURCES = $(sort $(CSOURCES))
@bagder

This comment has been minimized.

Show comment
Hide comment
@bagder

bagder Jun 21, 2017

Member

Thanks, fixed in 60c655a!

Member

bagder replied Jun 21, 2017

Thanks, fixed in 60c655a!

@User5910

This comment has been minimized.

Show comment
Hide comment
@User5910

User5910 Sep 18, 2017

I found that removing the call to buildconf.bat from winbuild/Makefile.vc prevents tool_hugehelp.c from getting generated when sync'd to 7.55.1.

User5910 replied Sep 18, 2017

I found that removing the call to buildconf.bat from winbuild/Makefile.vc prevents tool_hugehelp.c from getting generated when sync'd to 7.55.1.

@bagder

This comment has been minimized.

Show comment
Hide comment
@bagder

bagder Sep 18, 2017

Member

@User5910 if you build from git, you're supposed to invoke buildconf.bat, as documented in GIT-INFO. The makefile doesn't have to do that.

Member

bagder replied Sep 18, 2017

@User5910 if you build from git, you're supposed to invoke buildconf.bat, as documented in GIT-INFO. The makefile doesn't have to do that.

@User5910

This comment has been minimized.

Show comment
Hide comment
@User5910

User5910 Sep 18, 2017

Ah, thank you. I missed that part, and it just worked before this.

User5910 replied Sep 18, 2017

Ah, thank you. I missed that part, and it just worked before this.

Please sign in to comment.