Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/27.x' into 27.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
gruve-p committed Mar 10, 2024
2 parents 9588fb9 + c255fcb commit 44cfe28
Show file tree
Hide file tree
Showing 139 changed files with 17,676 additions and 9,732 deletions.
8 changes: 1 addition & 7 deletions build_msvc/test_bitcoin-qt/test_bitcoin-qt.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,13 @@
</PropertyGroup>
<ItemGroup>
<ClCompile Include="..\..\src\init\groestlcoin-qt.cpp" />
<ClCompile Include="..\..\src\test\util\setup_common.cpp" />
<ClCompile Include="..\..\src\wallet\test\util.cpp">
<ObjectFileName>$(IntDir)wallet_test_util.obj</ObjectFileName>
</ClCompile>
<ClCompile Include="..\..\src\qt\test\addressbooktests.cpp" />
<ClCompile Include="..\..\src\qt\test\apptests.cpp" />
<ClCompile Include="..\..\src\qt\test\optiontests.cpp" />
<ClCompile Include="..\..\src\qt\test\rpcnestedtests.cpp" />
<ClCompile Include="..\..\src\qt\test\test_main.cpp" />
<ClCompile Include="..\..\src\qt\test\uritests.cpp" />
<ClCompile Include="..\..\src\qt\test\util.cpp">
<ObjectFileName>$(IntDir)qt_test_util.obj</ObjectFileName>
</ClCompile>
<ClCompile Include="..\..\src\qt\test\util.cpp" />
<ClCompile Include="..\..\src\qt\test\wallettests.cpp" />
<ClCompile Include="..\..\src\wallet\test\wallet_test_fixture.cpp" />
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_addressbooktests.cpp" />
Expand Down
51 changes: 6 additions & 45 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
AC_PREREQ([2.69])
define(_CLIENT_VERSION_MAJOR, 26)
define(_CLIENT_VERSION_MINOR, 99)
define(_CLIENT_VERSION_MAJOR, 27)
define(_CLIENT_VERSION_MINOR, 0)
define(_CLIENT_VERSION_BUILD, 0)
define(_CLIENT_VERSION_RC, 0)
define(_CLIENT_VERSION_IS_RELEASE, false)
define(_CLIENT_VERSION_RC, 1)
define(_CLIENT_VERSION_IS_RELEASE, true)
define(_COPYRIGHT_YEAR, 2024)
define(_COPYRIGHT_HOLDERS,[The %s developers])
define(_COPYRIGHT_HOLDERS_SUBSTITUTION,[[Groestlcoin Core]])
Expand Down Expand Up @@ -249,16 +249,6 @@ AC_ARG_ENABLE([threadlocal],
[use_thread_local=$enableval],
[use_thread_local=auto])

AC_ARG_ENABLE([asm],
[AS_HELP_STRING([--disable-asm],
[disable assembly routines (enabled by default)])],
[use_asm=$enableval],
[use_asm=yes])

if test "$use_asm" = "yes"; then
AC_DEFINE([USE_ASM], [1], [Define this symbol to build in assembly routines])
fi

AC_ARG_ENABLE([zmq],
[AS_HELP_STRING([--disable-zmq],
[disable ZMQ notifications])],
Expand Down Expand Up @@ -432,10 +422,7 @@ if test "$CXXFLAGS_overridden" = "no"; then
AX_CHECK_COMPILE_FLAG([-Wsuggest-override], [WARN_CXXFLAGS="$WARN_CXXFLAGS -Wsuggest-override"], [], [$CXXFLAG_WERROR])
AX_CHECK_COMPILE_FLAG([-Wimplicit-fallthrough], [WARN_CXXFLAGS="$WARN_CXXFLAGS -Wimplicit-fallthrough"], [], [$CXXFLAG_WERROR])
AX_CHECK_COMPILE_FLAG([-Wunreachable-code], [WARN_CXXFLAGS="$WARN_CXXFLAGS -Wunreachable-code"], [], [$CXXFLAG_WERROR])

if test "$suppress_external_warnings" != "no" ; then
AX_CHECK_COMPILE_FLAG([-Wdocumentation], [WARN_CXXFLAGS="$WARN_CXXFLAGS -Wdocumentation"], [], [$CXXFLAG_WERROR])
fi
AX_CHECK_COMPILE_FLAG([-Wdocumentation], [WARN_CXXFLAGS="$WARN_CXXFLAGS -Wdocumentation"], [], [$CXXFLAG_WERROR])

dnl Some compilers (gcc) ignore unknown -Wno-* options, but warn about all
dnl unknown options if any other warning is produced. Test the -Wfoo case, and
Expand Down Expand Up @@ -463,8 +450,6 @@ enable_sse41=no
enable_avx2=no
enable_x86_shani=no

if test "$use_asm" = "yes"; then

dnl Check for optional instruction set support. Enabling these does _not_ imply that all code will
dnl be compiled with them, rather that specific objects/libs may use them after checking for runtime
dnl compatibility.
Expand Down Expand Up @@ -603,8 +588,6 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
)
CXXFLAGS="$TEMP_CXXFLAGS"

fi

CORE_CPPFLAGS="$CORE_CPPFLAGS -DHAVE_BUILD_INFO"

AC_ARG_WITH([utils],
Expand Down Expand Up @@ -975,7 +958,7 @@ if test "$TARGET_OS" = "darwin"; then
AX_CHECK_LINK_FLAG([-Wl,-fixup_chains], [HARDENED_LDFLAGS="$HARDENED_LDFLAGS -Wl,-fixup_chains"], [], [$LDFLAG_WERROR])
fi

AC_CHECK_HEADERS([endian.h sys/endian.h byteswap.h sys/select.h sys/prctl.h sys/sysctl.h vm/vm_param.h sys/vmmeter.h sys/resources.h])
AC_CHECK_HEADERS([sys/select.h sys/prctl.h sys/sysctl.h vm/vm_param.h sys/vmmeter.h sys/resources.h])

AC_CHECK_DECLS([getifaddrs, freeifaddrs],[CHECK_SOCKET],,
[#include <sys/types.h>
Expand All @@ -990,18 +973,6 @@ AC_CHECK_DECLS([pipe2])

AC_CHECK_FUNCS([timingsafe_bcmp])

AC_CHECK_DECLS([le16toh, le32toh, le64toh, htole16, htole32, htole64, be16toh, be32toh, be64toh, htobe16, htobe32, htobe64],,,
[#if HAVE_ENDIAN_H
#include <endian.h>
#elif HAVE_SYS_ENDIAN_H
#include <sys/endian.h>
#endif])

AC_CHECK_DECLS([bswap_16, bswap_32, bswap_64],,,
[#if HAVE_BYTESWAP_H
#include <byteswap.h>
#endif])

AC_MSG_CHECKING([for __builtin_clzl])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[
(void) __builtin_clzl(0);
Expand Down Expand Up @@ -1174,14 +1145,6 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h>
[ AC_MSG_RESULT([no])]
)

AC_MSG_CHECKING([for if type char equals int8_t])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <stdint.h>
#include <type_traits>]],
[[ static_assert(std::is_same<int8_t, char>::value, ""); ]])],
[ AC_MSG_RESULT([yes]); AC_DEFINE([CHAR_EQUALS_INT8], [1], [Define this symbol if type char equals int8_t]) ],
[ AC_MSG_RESULT([no])]
)

AC_MSG_CHECKING([for fdatasync])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <unistd.h>]],
[[ fdatasync(0); ]])],
Expand Down Expand Up @@ -1828,7 +1791,6 @@ AM_CONDITIONAL([ENABLE_AVX2], [test "$enable_avx2" = "yes"])
AM_CONDITIONAL([ENABLE_X86_SHANI], [test "$enable_x86_shani" = "yes"])
AM_CONDITIONAL([ENABLE_ARM_CRC], [test "$enable_arm_crc" = "yes"])
AM_CONDITIONAL([ENABLE_ARM_SHANI], [test "$enable_arm_shani" = "yes"])
AM_CONDITIONAL([USE_ASM], [test "$use_asm" = "yes"])
AM_CONDITIONAL([WORDS_BIGENDIAN], [test "$ac_cv_c_bigendian" = "yes"])
AM_CONDITIONAL([USE_NATPMP], [test "$use_natpmp" = "yes"])
AM_CONDITIONAL([USE_UPNP], [test "$use_upnp" = "yes"])
Expand Down Expand Up @@ -1983,7 +1945,6 @@ echo " with fuzz binary = $enable_fuzz_binary"
echo " with bench = $use_bench"
echo " with upnp = $use_upnp"
echo " with natpmp = $use_natpmp"
echo " use asm = $use_asm"
echo " USDT tracing = $use_usdt"
echo " sanitizers = $use_sanitizers"
echo " debug enabled = $enable_debug"
Expand Down
28 changes: 20 additions & 8 deletions contrib/seeds/makeseeds.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
PATTERN_IPV4 = re.compile(r"^((\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})):(\d+)$")
PATTERN_IPV6 = re.compile(r"^\[([0-9a-z:]+)\]:(\d+)$")
PATTERN_ONION = re.compile(r"^([a-z2-7]{56}\.onion):(\d+)$")
PATTERN_I2P = re.compile(r"^([a-z2-7]{52}\.b32.i2p):(\d+)$")
PATTERN_AGENT = re.compile(
r"^/Groestlcoin:("
r"2.13.(3)|"
Expand All @@ -35,10 +36,12 @@
r"2.18.(2)|"
r"2.19.(1)|"
r"2.20.(1)|"
r"2.21.(0|1|2|99)|"
r"22.(0|99)|"
r"24.(0|99)|"
r"25.99"
r"2.21.(0|1)|"
r"22.(0)|"
r"23.(0)|"
r"24.(0)|"
r"25.(0)|"
r"26.(0)|"
r")")

def parseline(line: str) -> Union[dict, None]:
Expand All @@ -63,7 +66,13 @@ def parseline(line: str) -> Union[dict, None]:
if m is None:
m = PATTERN_ONION.match(sline[0])
if m is None:
return None
m = PATTERN_I2P.match(sline[0])
if m is None:
return None
else:
net = 'i2p'
ipstr = sortkey = m.group(1)
port = int(m.group(2))
else:
net = 'onion'
ipstr = sortkey = m.group(1)
Expand Down Expand Up @@ -138,6 +147,7 @@ def filterbyasn(asmap: ASMap, ips: list[dict], max_per_asn: dict, max_per_net: i
# Sift out ips by type
ips_ipv46 = [ip for ip in ips if ip['net'] in ['ipv4', 'ipv6']]
ips_onion = [ip for ip in ips if ip['net'] == 'onion']
ips_i2p = [ip for ip in ips if ip['net'] == 'i2p']

# Filter IPv46 by ASN, and limit to max_per_net per network
result = []
Expand All @@ -161,6 +171,7 @@ def filterbyasn(asmap: ASMap, ips: list[dict], max_per_asn: dict, max_per_net: i

# Add back Onions (up to max_per_net)
result.extend(ips_onion[0:max_per_net])
result.extend(ips_i2p[0:max_per_net])
return result

def ip_stats(ips: list[dict]) -> str:
Expand All @@ -170,7 +181,7 @@ def ip_stats(ips: list[dict]) -> str:
if ip is not None:
hist[ip['net']] += 1

return f"{hist['ipv4']:6d} {hist['ipv6']:6d} {hist['onion']:6d}"
return f"{hist['ipv4']:6d} {hist['ipv6']:6d} {hist['onion']:6d} {hist['i2p']:6d}"

def parse_args():
argparser = argparse.ArgumentParser(description='Generate a list of groestlcoin node seed ip addresses.')
Expand All @@ -192,7 +203,7 @@ def main():
ips = [parseline(line) for line in lines]
print('Done.', file=sys.stderr)

print('\x1b[7m IPv4 IPv6 Onion Pass \x1b[0m', file=sys.stderr)
print('\x1b[7m IPv4 IPv6 Onion I2P Pass \x1b[0m', file=sys.stderr)
print(f'{ip_stats(ips):s} Initial', file=sys.stderr)
# Skip entries with invalid address.
ips = [ip for ip in ips if ip is not None]
Expand All @@ -206,11 +217,12 @@ def main():
# Require service bit 1.
ips = [ip for ip in ips if (ip['service'] & 1) == 1]
print(f'{ip_stats(ips):s} Require service bit 1', file=sys.stderr)
# Require at least 50% 30-day uptime for clearnet, 10% for onion.
# Require at least 50% 30-day uptime for clearnet, 10% for onion and i2p.
req_uptime = {
'ipv4': 50,
'ipv6': 50,
'onion': 10,
'i2p' : 10,
}
ips = [ip for ip in ips if ip['uptime'] > req_uptime[ip['net']]]
print(f'{ip_stats(ips):s} Require minimum uptime', file=sys.stderr)
Expand Down
8 changes: 0 additions & 8 deletions contrib/seeds/nodes_main.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
82.196.1.71:1331
37.139.19.131:1331
146.185.142.41:1331
146.185.142.49:1331
45.55.208.58:1331
45.55.208.60:1331
128.199.255.51:1331
128.199.138.187:1331
95.85.49.153:1331
95.85.60.40:1331
45.55.58.160:1331
Expand Down
4 changes: 2 additions & 2 deletions doc/design/assumeutxo.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ minimum and uses at least 1100 MiB.

As the background sync continues there will be temporarily two chainstate
directories, each multiple gigabytes in size (likely growing larger than the
the downloaded snapshot).
downloaded snapshot).

### Indexes

Expand Down Expand Up @@ -145,7 +145,7 @@ sequentially.

Once the tip of the background chainstate hits the base block of the snapshot
chainstate, we stop use of the background chainstate by setting `m_disabled`, in
`CompleteSnapshotValidation()`, which is checked in `ActivateBestChain()`). We hash the
`MaybeCompleteSnapshotValidation()`, which is checked in `ActivateBestChain()`). We hash the
background chainstate's UTXO set contents and ensure it matches the compiled value in
`CMainParams::m_assumeutxo_data`.

Expand Down
7 changes: 0 additions & 7 deletions doc/developer-notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -577,13 +577,6 @@ export UBSAN_OPTIONS="suppressions=$(pwd)/test/sanitizer_suppressions/ubsan:prin
See the CI config for more examples, and upstream documentation for more information
about any additional options.

There are a number of known problems when using the `address` sanitizer. The
address sanitizer is known to fail in
[sha256_sse4::Transform](/src/crypto/sha256_sse4.cpp) which makes it unusable
unless you also use `--disable-asm` when running configure. We would like to fix
sanitizer issues, so please send pull requests if you can fix any errors found
by the address sanitizer (or any other sanitizer).

Not all sanitizer options can be enabled at the same time, e.g. trying to build
with `--with-sanitizers=address,thread` will fail in the configure script as
these sanitizers are mutually incompatible. Refer to your compiler manual to
Expand Down
7 changes: 1 addition & 6 deletions doc/fuzzing.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,19 +148,14 @@ The default Clang/LLVM version supplied by Apple on macOS does not include
fuzzing libraries, so macOS users will need to install a full version, for
example using `brew install llvm`.
Should you run into problems with the address sanitizer, it is possible you
may need to run `./configure` with `--disable-asm` to avoid errors
with certain assembly code from Groestlcoin Core's code. See [developer notes on sanitizers](https://github.com/groestlcoin/groestlcoin/blob/master/doc/developer-notes.md#sanitizers)
for more information.
You may also need to take care of giving the correct path for `clang` and
`clang++`, like `CC=/path/to/clang CXX=/path/to/clang++` if the non-systems
`clang` does not come first in your path.
Full configure that was tested on macOS with `brew` installed `llvm`:
```sh
./configure --enable-fuzz --with-sanitizers=fuzzer,address,undefined --disable-asm CC=$(brew --prefix llvm)/bin/clang CXX=$(brew --prefix llvm)/bin/clang++
./configure --enable-fuzz --with-sanitizers=fuzzer,address,undefined CC=$(brew --prefix llvm)/bin/clang CXX=$(brew --prefix llvm)/bin/clang++
```
Read the [libFuzzer documentation](https://llvm.org/docs/LibFuzzer.html) for more information. This [libFuzzer tutorial](https://github.com/google/fuzzing/blob/master/tutorial/libFuzzerTutorial.md) might also be of interest.
Expand Down
8 changes: 7 additions & 1 deletion doc/man/groestlcoin-cli.1
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,10 @@
.SH NAME
groestlcoin-cli \- manual page for groestlcoin-cli

This is a placeholder file. Please follow the instructions in \fIcontrib/devtools/README.md\fR to generate the manual pages after a release.
Please contribute if you find Bitcoin Core useful. Visit
<https://bitcoincore.org/> for further information about the software.
The source code is available from <https://github.com/bitcoin/bitcoin>.

This is experimental software.
Distributed under the MIT software license, see the accompanying file COPYING
or <https://opensource.org/licenses/MIT>
8 changes: 7 additions & 1 deletion doc/man/groestlcoin-qt.1
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,10 @@
.SH NAME
groestlcoin-qt \- manual page for groestlcoin-qt

This is a placeholder file. Please follow the instructions in \fIcontrib/devtools/README.md\fR to generate the manual pages after a release.
Please contribute if you find Bitcoin Core useful. Visit
<https://bitcoincore.org/> for further information about the software.
The source code is available from <https://github.com/bitcoin/bitcoin>.

This is experimental software.
Distributed under the MIT software license, see the accompanying file COPYING
or <https://opensource.org/licenses/MIT>
8 changes: 7 additions & 1 deletion doc/man/groestlcoin-tx.1
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,10 @@
.SH NAME
groestlcoin-tx \- manual page for groestlcoin-tx

This is a placeholder file. Please follow the instructions in \fIcontrib/devtools/README.md\fR to generate the manual pages after a release.
Please contribute if you find Bitcoin Core useful. Visit
<https://bitcoincore.org/> for further information about the software.
The source code is available from <https://github.com/bitcoin/bitcoin>.

This is experimental software.
Distributed under the MIT software license, see the accompanying file COPYING
or <https://opensource.org/licenses/MIT>
8 changes: 7 additions & 1 deletion doc/man/groestlcoind.1
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,10 @@
.SH NAME
groestlcoind \- manual page for groestlcoind

This is a placeholder file. Please follow the instructions in \fIcontrib/devtools/README.md\fR to generate the manual pages after a release.
Please contribute if you find Bitcoin Core useful. Visit
<https://bitcoincore.org/> for further information about the software.
The source code is available from <https://github.com/bitcoin/bitcoin>.

This is experimental software.
Distributed under the MIT software license, see the accompanying file COPYING
or <https://opensource.org/licenses/MIT>
2 changes: 1 addition & 1 deletion doc/offline-signing-tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ At this point, it's important to understand that both the `offline_wallet` and o
tgrs1qtu5qgc6ddhmqm5yqjvhg83qgk2t4ewajg0h6yh
```

2. Visit a faucet like https://signet.bc-2.jp and enter your address from the previous command to receive a small amount of signet coins to this address.
2. Visit a faucet like https://signetfaucet.com and enter your address from the previous command to receive a small amount of signet coins to this address.

3. Confirm that coins were received using the online `watch_only_wallet`. Note that the transaction may take a few moments before being received on your local node, depending on its connectivity. Just re-run the command periodically until the transaction is received.

Expand Down
7 changes: 0 additions & 7 deletions doc/release-notes-28207.md

This file was deleted.

15 changes: 0 additions & 15 deletions doc/release-notes-29189.md

This file was deleted.

Loading

0 comments on commit 44cfe28

Please sign in to comment.