From b39be185b752fcb05dac2d0b0498676b9a31344d Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Fri, 3 Jan 2025 19:28:58 +0100 Subject: [PATCH 1/4] scripts/Windows/README.adoc: clarify envvar persistence for the build Signed-off-by: Jim Klimov --- scripts/Windows/README.adoc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/scripts/Windows/README.adoc b/scripts/Windows/README.adoc index a1da002cc1..4b0941d3f3 100644 --- a/scripts/Windows/README.adoc +++ b/scripts/Windows/README.adoc @@ -81,8 +81,14 @@ dependencies as detailed below. ================================================================================ If you use script `./build-mingw-nut.sh` mentioned below, you may skip setting -these environment variables when building NUT. You would however need to use -them once (per `ARCH`) to provide the prerequisites below if built from source. +these environment variables when building NUT itself. You would however need +to use them once (per `ARCH`) to provide the prerequisites below if they are +built from source. + +The build routines detailed below expect to be run in a terminal (shell per +`ARCH`) with all these environment variables set once and inherited from one +component build to another. Should you need to rebuild something, you would +have to set these variables again in that session. When using the compilation approach, you would typically use the following `ARCH`, `HOST_FLAG` and `BUILD_FLAG`, as well as `CC`, `CFLAGS`, `LDFLAGS` From 1317583a0cdc7ddedbad76faf1a1abb6367784e8 Mon Sep 17 00:00:00 2001 From: RikyPlaza <158032745+RikyPlaza@users.noreply.github.com> Date: Thu, 19 Dec 2024 08:51:36 +0000 Subject: [PATCH 2/4] scripts/Windows/README.adoc: corrected instructions of pthread installation Signed-off-by: RikyPlaza <158032745+RikyPlaza@users.noreply.github.com> --- scripts/Windows/README.adoc | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/scripts/Windows/README.adoc b/scripts/Windows/README.adoc index 4b0941d3f3..98f43154e3 100644 --- a/scripts/Windows/README.adoc +++ b/scripts/Windows/README.adoc @@ -228,9 +228,12 @@ presumed inconsequential. You can try a not-"inlined" build instead. Finally, install the resulting files into locations under `PREFIX`: - :; sudo cp *.dll ${PREFIX}/pthreads/lib/ - :; sudo cp *.a ${PREFIX}/lib/ - :; sudo cp pthread.h sched.h semaphore.h ${PREFIX}/pthreads/include + :; sudo mkdir -p $PREFIX/pthreads/lib/ + :; sudo cp *.dll $PREFIX/pthreads/lib/ + :; sudo mkdir -p $PREFIX/lib/ + :; sudo cp *.a $PREFIX/lib/ + :; sudo mkdir -p $PREFIX/pthreads/include/ + :; sudo cp pthread.h sched.h semaphore.h $PREFIX/pthreads/include MinGW regex library From 7ce8cd541fd2f59dfe80d0a7b532d07e6f4d5a13 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Fri, 3 Jan 2025 19:29:34 +0100 Subject: [PATCH 3/4] scripts/Windows/README.adoc: fix markup for pthreads installation Signed-off-by: Jim Klimov --- scripts/Windows/README.adoc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/Windows/README.adoc b/scripts/Windows/README.adoc index 98f43154e3..e911fd6c88 100644 --- a/scripts/Windows/README.adoc +++ b/scripts/Windows/README.adoc @@ -228,12 +228,12 @@ presumed inconsequential. You can try a not-"inlined" build instead. Finally, install the resulting files into locations under `PREFIX`: - :; sudo mkdir -p $PREFIX/pthreads/lib/ - :; sudo cp *.dll $PREFIX/pthreads/lib/ - :; sudo mkdir -p $PREFIX/lib/ - :; sudo cp *.a $PREFIX/lib/ - :; sudo mkdir -p $PREFIX/pthreads/include/ - :; sudo cp pthread.h sched.h semaphore.h $PREFIX/pthreads/include + :; sudo mkdir -p "${PREFIX}/pthreads/lib/" + :; sudo cp *.dll "${PREFIX}/pthreads/lib/" + :; sudo mkdir -p "${PREFIX}/lib/" + :; sudo cp *.a "${PREFIX}/lib/" + :; sudo mkdir -p "${PREFIX}/pthreads/include/" + :; sudo cp pthread.h sched.h semaphore.h "${PREFIX}/pthreads/include/" MinGW regex library From 2e9576805651bb11700006b645b3e254c1e14995 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Fri, 3 Jan 2025 19:45:05 +0100 Subject: [PATCH 4/4] scripts/Windows/README.adoc: remind about prerequisite installation Signed-off-by: Jim Klimov Signed-off-by: RikyPlaza <158032745+RikyPlaza@users.noreply.github.com> --- scripts/Windows/README.adoc | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/scripts/Windows/README.adoc b/scripts/Windows/README.adoc index e911fd6c88..97af6b214b 100644 --- a/scripts/Windows/README.adoc +++ b/scripts/Windows/README.adoc @@ -77,6 +77,21 @@ On Redhat and similar systems, use: You will also need pthread and mingw regex libraries, and other recommended dependencies as detailed below. +[NOTE] +====== +Be sure to install NUT build prerequisites and toolkits, as detailed +in `docs/config-prereqs.txt` file. + +If builds complain similarly to +---- +syntax error near unexpected token 'LIBUSB_1_0,' + 'PKG_CHECK_MODULES(LIBUSB_1_0, libusb-1.0 >= 0.9.1)' +---- +make sure you have installed `pkgconf`, e.g.: + + # apt-get install pkgconf +====== + [NOTE] ================================================================================