Daniel Stenberg
d48dd1573c
config: remove the check for and use of SIZEOF_SHORT
...
shorts are 2 bytes on all platforms curl runs and have ever run on.
Closes #9291
2022-08-11 09:07:06 +02:00
Viktor Szakats
4d73854462
tidy-up: delete unused build configuration macros
...
Most of them feature guards:
- `CURL_INCLUDES_SYS_UIO` [1]
- `HAVE_ALLOCA_H` [2]
- `HAVE_CRYPTO_CLEANUP_ALL_EX_DATA` (unused since de71e68000
)
- `HAVE_DLFCN_H`
- `HAVE_DLOPEN`
- `HAVE_DOPRNT`
- `HAVE_FCNTL`
- `HAVE_GETHOSTBYNAME` [3]
- `HAVE_GETOPT_H`
- `HAVE_GETPASS`
- `HAVE_GETPROTOBYNAME`
- `HAVE_GETSERVBYNAME`
- `HAVE_IDN_FREE*`
- `HAVE_INET_ADDR`
- `HAVE_IOCTL`
- `HAVE_KRB4`
- `HAVE_KRB_GET_OUR_IP_FOR_REALM`
- `HAVE_KRB_H`
- `HAVE_LDAPSSL_H`
- `HAVE_LDAP_INIT_FD`
- `HAVE_LIBDL`
- `HAVE_LIBNSL`
- `HAVE_LIBRESOLV*`
- `HAVE_LIBUCB`
- `HAVE_LL`
- `HAVE_LOCALTIME_R`
- `HAVE_MALLOC_H`
- `HAVE_MEMCPY`
- `HAVE_MEMORY_H`
- `HAVE_NETINET_IF_ETHER_H`
- `HAVE_NI_WITHSCOPEID`
- `HAVE_OPENSSL_CRYPTO_H`
- `HAVE_OPENSSL_ERR_H`
- `HAVE_OPENSSL_PEM_H`
- `HAVE_OPENSSL_PKCS12_H`
- `HAVE_OPENSSL_RAND_H`
- `HAVE_OPENSSL_RSA_H`
- `HAVE_OPENSSL_SSL_H`
- `HAVE_OPENSSL_X509_H`
- `HAVE_PEM_H`
- `HAVE_POLL`
- `HAVE_RAND_SCREEN`
- `HAVE_RAND_STATUS`
- `HAVE_RECVFROM`
- `HAVE_SETSOCKOPT`
- `HAVE_SETVBUF`
- `HAVE_SIZEOF_LONG_DOUBLE`
- `HAVE_SOCKIO_H`
- `HAVE_SOCK_OPTS`
- `HAVE_STDIO_H`
- `HAVE_STRCASESTR`
- `HAVE_STRFTIME`
- `HAVE_STRLCAT`
- `HAVE_STRNCMPI`
- `HAVE_STRNICMP`
- `HAVE_STRSTR`
- `HAVE_STRUCT_IN6_ADDR`
- `HAVE_TLD_H`
- `HAVE_TLD_STRERROR`
- `HAVE_UNAME`
- `HAVE_USLEEP`
- `HAVE_WINBER_H`
- `HAVE_WRITEV`
- `HAVE_X509_H`
- `LT_OBJDIR`
- `NEED_BASENAME_PROTO`
- `NOT_NEED_LIBNSL`
- `OPENSSL_NO_KRB5`
- `RECVFROM_TYPE*`
- `SIZEOF_LONG_DOUBLE`
- `STRERROR_R_TYPE_ARG3`
- `USE_YASSLEMUL`
- `_USRDLL` (from CMake) [4]
[1] Related parts in `m4/curl-functions.m4` and `configure.ac` might
also be deleted.
[2] Related comment can possibly be deleted in
`packages/vms/generate_config_vms_h_curl.com`.
[3] There are more instances of this in autotools, but I did not dare to
touch those. Looked like it's used to detect socket support.
[4] This is necessary for MFC (Microsoft Foundation Class) DLLs to
force linking MFC components statically to the DLL. `libcurl.dll`
does not use MFC, so we can delete this define.
Ref: https://docs.microsoft.com/cpp/build/regular-dlls-statically-linked-to-mfc
Script that can help finding unused settings like above:
```shell
autoheader configure.ac # generate lib/curl_config.h.in
{
grep -o -E 'set\([A-Z][A-Z0-9_]{3,}' CMake/Platforms/WindowsCache.cmake | sed -E 's|set\(||g'
grep -o -E -h '#define +[A-Z][A-Z0-9_]{3,}' lib/config-*.h | sed -E 's|#define +||g'
grep -o -E '#cmakedefine +[A-Z][A-Z0-9_]{3,}' lib/curl_config.h.cmake | sed -E 's|#cmakedefine +||g'
grep -o -E '#undef +[A-Z][A-Z0-9_]{3,}' lib/curl_config.h.in | sed -E 's|#undef +||g'
} | sort -u | grep -v -F 'HEADER_CURL_' | while read -r def; do
c="$(git grep -w -F "${def}" | grep -v -E -c '(/libcurl\.tmpl|^lib/config-|^lib/curl_config\.h\.cmake|^CMakeLists\.txt|^CMake/Platforms/WindowsCache\.cmake|^packages/vms/config_h\.com|^m4/curl-functions\.m4|^acinclude\.m4|^configure\.ac)')"
if [ "${c}" = '0' ]; then
echo "${def}"
fi
done
```
Reviewed-by: Daniel Stenberg
Closes #9044
2022-07-19 15:12:19 +00:00
max.mehl
ad9bc5976d
copyright: make repository REUSE compliant
...
Add licensing and copyright information for all files in this repository. This
either happens in the file itself as a comment header or in the file
`.reuse/dep5`.
This commit also adds a Github workflow to check pull requests and adapts
copyright.pl to the changes.
Closes #8869
2022-06-13 09:13:00 +02:00
Marcel Raad
60300291fd
config: remove `HAVE_WINSOCK_H` definition
...
It's not used anymore.
Closes https://github.com/curl/curl/pull/7795
2021-09-29 15:54:33 +02:00
Daniel Stenberg
180180a44d
Revert "build: remove checks for WinSock 1"
...
Due to CI issues
This reverts commit c2ea04f92b
.
Closes #7790
2021-09-29 10:42:49 +02:00
Marcel Raad
c2ea04f92b
build: remove checks for WinSock 1
...
It's not supported anymore.
Closes https://github.com/curl/curl/pull/7778
2021-09-28 19:29:27 +02:00
Dan Fandrich
83245d9ff3
Get rid of the unused HAVE_SIG_ATOMIC_T et. al.
...
It was added in 2006 but I see no evidence it was ever used.
2021-07-23 12:40:42 -07:00
Gergely Nagy
6f5ff0ee04
configure/cmake: remove checks for unused gethostbyaddr and gethostbyaddr_r
...
Closes #7276
2021-06-18 13:52:21 +02:00
Gergely Nagy
e92603289a
configure/cmake: remove unused define HAVE_PERROR
...
Closes #7276
2021-06-18 13:52:16 +02:00
Gergely Nagy
a407a82d0b
configure/cmake: remove checks for unused sgtty.h
...
Closes #7276
2021-06-18 13:52:02 +02:00
Gergely Nagy
8c24cf5238
configure/cmake: remove remaining checks for rsa.h
...
Closes #7276
2021-06-18 13:51:59 +02:00
Gergely Nagy
baae00f66b
configure/cmake: remove remaining checks for err.h
...
Closes #7276
2021-06-18 13:51:57 +02:00
Gergely Nagy
376d2380d2
configure/cmake: remove remaining checks for crypto.h
...
Closes #7276
2021-06-18 13:51:54 +02:00
Marc Aldorasi
f6b325a509
config: remove now-unused macros
...
Closes #7094
2021-05-19 00:36:01 +02:00
Daniel Stenberg
8419fe4d88
cmake: check for getppid and utimes
...
... as they're checked for in the configure script and are used by
source code.
Removed checks for perror, setvbuf and strlcat since those defines are
not checked for in source code.
Bonus: removed HAVE_STRLCPY from a few config-*.h files since that
symbol is not used in source code.
Closes #6997
2021-05-04 14:46:55 +02:00
Michael Forney
812fce9dcf
configure: remove use of RETSIGTYPE
...
This was previously defined by the obsolete AC_TYPE_SIGNAL macro,
which was removed in 2682e5f5
. The deprecation text says
> Your code may safely assume C89 semantics that RETSIGTYPE is void.
So, remove it and just use void instead.
Closes #6861
2021-04-07 16:01:05 +02:00
Viktor Szakats
95014b0a4d
build: delete unused feature guards
...
- `HAVE_STRNCASECMP`
- `HAVE_TCGETATTR`
- `HAVE_TCSETATTR`
Reviewed-by: Jay Satiro
Reviewed-by: Daniel Stenberg
Closes #6645
2021-02-23 12:04:29 +00:00
Daniel Stenberg
4d2f800677
curl.se: new home
...
Closes #6172
2020-11-04 23:59:47 +01:00
Daniel Stenberg
2edeb10457
config: remove all defines of HAVE_DES_H
...
As there's no code using it.
Closes #5144
2020-03-24 17:54:26 +01:00
Vilhelm Prytz
d0319adb0c
copyrights: update all copyright notices to 2019 on files changed this year
...
Closes #4547
2019-11-02 23:15:56 +01:00
Paul B. Omta
df85b86a92
build: Remove unused HAVE_LIBSSL and HAVE_LIBCRYPTO defines
...
Closes https://github.com/curl/curl/pull/4460
2019-10-05 19:18:30 -04:00
Daniel Stenberg
4af40b3646
URLs: change all http:// URLs to https://
2016-02-03 00:19:02 +01:00
Daniel Stenberg
358c5c0745
strlcat: remove function
...
This function was only used twice, both in places where performance
isn't crucial (socks + if2ip). Removing the use of this function removes
the need to have our private version for systems without it == reduced
amount of code.
Also, in the SOCKS case it is clearly better to fail gracefully rather
than to truncate the results.
This work was triggered by a bug report on the strcal prototype in
strequal.h.
strlcat was added in commit db70cd28
in February 2001!
Bug: http://curl.haxx.se/bug/view.cgi?id=1192
Reported by: Jeremy Huddleston
2013-02-14 10:41:45 +01:00
Yang Tse
919c97fa65
curl tool: use configuration files from lib directory
...
Configuration files such as curl_config.h and all config-*.h no longer exist
nor are generated/copied into 'src' directory, now these only exist in 'lib'
directory from where curl tool sources uses them.
Additionally old src/setup.h has been refactored into src/tool_setup.h which
now pulls lib/setup.h
The possibility of a makefile needing an include path adjustment exists.
2012-04-06 23:37:05 +02:00
Yang Tse
ef2176109f
errno.h inclusion conditionally done in setup_once.h
2011-07-24 04:39:43 +02:00
Daniel Stenberg
1aeb635cdd
sources: update source headers
...
All C and H files now (should) feature the proper project curl source
code header, which includes basic info, a copyright statement and some
basic disclaimers.
2011-03-10 12:04:33 +01:00
Yang Tse
99a07a1fdf
build: provide SIZEOF_SIZE_T definition for non-configure builds
2010-12-02 21:41:23 +01:00
Yang Tse
cef95aadeb
Added SIZEOF_INT and SIZEOF_SHORT definitions for non-configure systems
2010-02-26 18:32:46 +00:00
Yang Tse
581ce03345
Remove enable-thread / disable-thread configure option. These were only placebo
...
options. The library is always built as thread safe as possible on every system.
2009-11-15 02:45:23 +00:00
Gunter Knauf
f671d0513c
renamed generated config.h to curl_config.h in order to avoid clashes when libcurl is used with other projects which also have a config.h.
2009-07-14 13:25:14 +00:00
Yang Tse
9137e717b0
Use build-time configured curl_socklen_t instead of socklen_t
2009-05-02 02:37:32 +00:00
Gunter Knauf
1cc50d31f9
changed HAVE_SIN6_SCOPE_ID define to HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID since just found that ares already uses this define.
2008-12-30 08:05:38 +00:00
Gunter Knauf
104377d718
added HAVE_SIN6_SCOPE_ID define to all non-configure platforms which seem to be IPv6-aware.
2008-12-30 07:31:04 +00:00
Yang Tse
a15b6a6f86
the IP address we want/request/use from the interface is the 'local'
...
address, the one on the box libcurl is running, not the 'remote' one.
2008-11-17 19:08:35 +00:00
Yang Tse
608fdce0a0
if2ip.c related preprocessor cleanup
2008-11-17 14:24:15 +00:00
Yang Tse
17d2a464ad
Refactor configure script detection of functions used to set sockets into
...
non-blocking mode, and decouple function detection from function capability.
2008-11-13 18:56:55 +00:00
Yang Tse
4e909ee8b1
ntoa() and inet_ntoa_r() no longer used
2008-09-24 12:22:16 +00:00
Yang Tse
19bc92289d
HAVE_ALARM definition for static config-*.h files
2008-09-19 23:51:16 +00:00
Yang Tse
bffe69a151
when recvfrom prototype uses a void pointer for arguments 2, 5 or 6 this will
...
now cause the definition of RECVFROM_TYPE_ARG2_IS_VOID, RECVFROM_TYPE_ARG5_IS_VOID
or RECVFROM_TYPE_ARG6_IS_VOID, as appropriate.
2008-07-21 00:36:55 +00:00
Yang Tse
39f23aec6b
RECVFROM_TYPE_ARG2, RECVFROM_TYPE_ARG5 and RECVFROM_TYPE_ARG6 are now defined
...
to the data type pointed by its respective argument and not the pointer type.
2008-07-17 03:07:54 +00:00
Yang Tse
a9dc900515
Configure process now checks availability of recvfrom() socket function and
...
finds out its return type and the types of its arguments. Added definitions
for non-configure systems config files, and introduced macro sreadfrom which
will be used on udp sockets as a recvfrom() wrapper.
2008-07-16 19:16:41 +00:00
Yang Tse
0163b5b8be
fix: socklen_t definition comment
2008-05-21 13:57:50 +00:00
Daniel Stenberg
d0edb47896
Patrick Monnerat modified the LDAP code and approach in curl. Starting now,
...
the configure script checks for openldap and friends and we link with those
libs just like we link all other third party libraries, and we no longer
dlopen() those libraries. Our private header file lib/ldap.h was renamed to
lib/curl_ldap.h due to this. I set a tag in CVS (curl-7_17_0-preldapfix)
just before this commit, just in case.
2007-08-11 20:57:54 +00:00
Yang Tse
bcd8a3b240
Define HAVE_SIGNAL_H, HAVE_SIG_ATOMIC_T and HAVE_SIG_ATOMIC_T_VOLATILE
...
as appropriate for platforms that don't have autotools support
2006-11-24 16:38:58 +00:00
Yang Tse
dc3ed35313
Define HAVE_STRUCT_TIMEVAL as appropriate for platforms that lack autotools support
2006-10-14 12:01:44 +00:00
Yang Tse
13616f8f96
Simplify check for NEED_MALLOC_H, and make more explicit that NEED_MALLOC_H shall be defined if <malloc.h> header file must be included even when including <stdlib.h>.
2006-07-25 13:49:49 +00:00
Yang Tse
fe22872d14
include <malloc.h> only if HAVE_MALLOC_H and NEED_MALLOC_H are both defined.
2006-07-11 21:34:23 +00:00
Yang Tse
7e43d06b60
Get qualifier of arg 2 for send() apart into SEND_QUAL_ARG2.
2006-07-04 16:54:10 +00:00
Yang Tse
89f54f3739
Platforms that don't have/run configure need default values in their config files for:
...
HAVE_GETNAMEINFO, GETNAMEINFO_QUAL_ARG1, GETNAMEINFO_TYPE_ARG1, GETNAMEINFO_TYPE_ARG2, GETNAMEINFO_TYPE_ARG46, GETNAMEINFO_TYPE_ARG7
HAVE_RECV, RECV_TYPE_ARG1, RECV_TYPE_ARG2, RECV_TYPE_ARG3, RECV_TYPE_ARG4, RECV_TYPE_RETV
HAVE_SEND, SEND_TYPE_ARG1, SEND_TYPE_ARG2, SEND_TYPE_ARG3, SEND_TYPE_ARG4, SEND_TYPE_RETV
2006-07-04 16:10:13 +00:00
Dan Fandrich
205f8b266c
Fixed LDAP library file name bug (KNOWN_BUGS #1 ). configure now auto-detects
...
the correct dynamic library names by default, and provides override switches
--with-ldap-lib, --with-lber-lib and --without-lber-lib. Added
CURL_DISABLE_LDAP to platform-specific config files to disable LDAP
support on those platforms that probably don't have dynamic OpenLDAP
libraries available to avoid compile errors.
2005-03-11 05:28:07 +00:00