Skip to content

cmake, doc: Amend Windows build notes - #299

Merged
hebasto merged 1 commit into
cmake-stagingfrom
240802-cmake-IA
Aug 6, 2024
Merged

hebasto merged 1 commit into
cmake-stagingfrom
240802-cmake-IA

Conversation

@hebasto

@hebasto hebasto commented Aug 2, 2024

Copy link
Copy Markdown
Owner

Tested on Windows 11 + WSL + Ubuntu 24.04.

Cleaned up old workaronds (bitcoin#11437 and bitcoin#19408) which no longer seem required.

@hebasto

hebasto commented Aug 2, 2024

Copy link
Copy Markdown
Owner Author

Friendly ping @sipsorcery @fanquake @pablomartin4btc @m3dwards :)

Comment thread doc/build-windows.md
Build using:

PATH=$(echo "$PATH" | sed -e 's/:\/mnt.*//g') # strip out problematic Windows %PATH% imported var
sudo bash -c "echo 0 > /proc/sys/fs/binfmt_misc/status" # Disable WSL support for Win32 applications.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aren't the above 2 lines still needed if building with cmake on WSL?

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, those 2 lines are not needed. I have tested this on Windows 11 using WSL and confirmed that the build process works correctly without them.

I hope you'll be able to build as well.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've additionally verified build logs for the bdb and sqlite packages. Enabling or disabling binfmt_misc makes no difference.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is the case, then it should just be removed in master? Given this isn't related to CMake.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is the case, then it should just be removed in master? Given this isn't related to CMake.

The root configure script in the master branch is still affected:

$ diff -u ~/configure_binfmt_disabled ~/configure_binfmt_enabled
--- /home/hebasto/configure_binfmt_disabled     2024-08-06 15:52:36.633707879 +0100
+++ /home/hebasto/configure_binfmt_enabled      2024-08-06 15:50:27.099730962 +0100
@@ -15,7 +15,7 @@
 checking whether the C++ compiler works... yes
 checking for C++ compiler default output file name... a.exe
 checking for suffix of executables... .exe
-checking whether we are cross compiling... yes
+checking whether we are cross compiling... no
 checking for suffix of object files... o
 checking whether the compiler supports GNU C++... yes
 checking whether x86_64-w64-mingw32-g++-posix accepts -g... yes
@@ -50,7 +50,6 @@
 checking for /usr/bin/x86_64-w64-mingw32-ld option to reload object files... -r
 checking for x86_64-w64-mingw32-file... no
 checking for file... file
-configure: WARNING: using cross tools not prefixed with host triplet
 checking for x86_64-w64-mingw32-objdump... x86_64-w64-mingw32-objdump
 checking how to recognize dependent libraries... (cached) pass_all
 checking for x86_64-w64-mingw32-dlltool... x86_64-w64-mingw32-dlltool
@@ -351,7 +350,7 @@
 checking whether the C compiler works... yes
 checking for C compiler default output file name... a.exe
 checking for suffix of executables... .exe
-checking whether we are cross compiling... yes
+checking whether we are cross compiling... no
 checking for suffix of object files... o
 checking whether the compiler supports GNU C... yes
 checking whether x86_64-w64-mingw32-gcc accepts -g... yes
@@ -378,7 +377,6 @@
 checking for /usr/bin/x86_64-w64-mingw32-ld option to reload object files... -r
 checking for x86_64-w64-mingw32-file... no
 checking for file... file
-configure: WARNING: using cross tools not prefixed with host triplet
 checking for x86_64-w64-mingw32-objdump... x86_64-w64-mingw32-objdump
 checking how to recognize dependent libraries... file_magic ^x86 archive import|^x86 DLL
 checking for x86_64-w64-mingw32-dlltool... x86_64-w64-mingw32-dlltool

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is the case, then it should just be removed in master? Given this isn't related to CMake.

Please see bitcoin#30597 for the first removed line.

@hebasto

hebasto commented Aug 5, 2024

Copy link
Copy Markdown
Owner Author

Rebased.

@m3dwards

m3dwards commented Aug 5, 2024

Copy link
Copy Markdown

ACK 87b4c08

Using instructions I was able to build, test and create windows installer using WSL (Ubuntu 24.04 based)

@hebasto
hebasto merged commit 93a8066 into cmake-staging Aug 6, 2024
hebasto pushed a commit that referenced this pull request Jul 7, 2026
….makePool` method

6b0a907 Squashed 'src/ipc/libmultiprocess/' changes from 3edbe8f..16bf05d (Ryan Ofsky)

Pull request description:

  The changes can be verified by running `test/lint/git-subtree-check.sh src/ipc/libmultiprocess` as described in [developer notes](https://github.com/bitcoin/bitcoin/blob/master/doc/developer-notes.md#subtrees) and [lint instructions](https://github.com/bitcoin/bitcoin/tree/master/test/lint#git-subtree-checksh).

  Changes since last subtree update (bitcoin#34977):

  - Adds `makePool` method on `ThreadMap` to support thread pool routing, allowing requests without a specific client thread to be dispatched to a pool using a shortest-queue strategy ([#283](bitcoin-core/libmultiprocess#283)).
  - Adds `std::unordered_set` support, a `BuildList` helper, and a `ReadList` helper to reduce duplication in list build and read handlers ([#277](bitcoin-core/libmultiprocess#277), [#285](bitcoin-core/libmultiprocess#285)).
  - Adds support for translating C++ `std::optional<T>` struct fields to pairs of `T` + `hasT :Bool` Cap'n Proto struct fields, allowing unset optional primitive fields to be represented ([#243](bitcoin-core/libmultiprocess#243)).
  - Produces more readable log output for Proxy object lifecycle events and IPC server-side failures ([#218](bitcoin-core/libmultiprocess#218)).
  - Handles exceptions thrown by `destroy` methods by logging instead of aborting ([#273](bitcoin-core/libmultiprocess#273)). This can prevent server crashes when non-libmultiprocess clients disconnect without destroying objects, in the case where a server object owns client objects and the server destructor tries to call the disconnected client to free them ([#219](bitcoin-core/libmultiprocess#219)).
  - Handles unexpected exceptions thrown by callbacks (that should never happen) by logging errors instead of deadlocking ([#260](bitcoin-core/libmultiprocess#260)).
  - Fixes a rare mptest hang on musl builds caused by a lost wakeup bug in `Waiter` ([#295](bitcoin-core/libmultiprocess#295)).
  - Fixes a race condition in a log print detected by TSan ([#286](bitcoin-core/libmultiprocess#286)).
  - Build improvements: makes `target_capnp_sources` work correctly when libmultiprocess is used as a CMake subproject ([#289](bitcoin-core/libmultiprocess#289)), adds `mp_headers` target for better lint tool support ([#291](bitcoin-core/libmultiprocess#291)), and fixes compatibility with recent Nix and CMake 4.0 ([#238](bitcoin-core/libmultiprocess#238)).
  - Test, CI, documentation, and minor code improvements: design document corrections ([#278](bitcoin-core/libmultiprocess#278)), field constant comments ([#279](bitcoin-core/libmultiprocess#279)), clang-tidy fix ([#292](bitcoin-core/libmultiprocess#292)), new smoke test for double-precision float values ([#294](bitcoin-core/libmultiprocess#294)), new test for recursive async IPC calls ([#301](bitcoin-core/libmultiprocess#301)), removal of libevent from Core CI builds ([#299](bitcoin-core/libmultiprocess#299)), and rename of `EventLoop::m_num_clients` to `m_num_refs` ([#302](bitcoin-core/libmultiprocess#302)).

ACKs for top commit:
  fanquake:
    ACK 02afa66
  hebasto:
    ACK 02afa66.

Tree-SHA512: ef81a951c971f328a0a98436030467eeea30925eb6016eafd9bc7a25726c87628a852bbb1d84b88bce340aeea2bed25c65bc55db1168ebcb850628cd18808883
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Docs and manuals

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants