From: sgn <sgn@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] cmake less cursed template, ship manpages, switch GUI to Qt6, and update
Date: Mon, 28 Jun 2021 17:33:23 +0200 [thread overview]
Message-ID: <20210628153323.xs9TQl1L3z9hiB9OUPj6nVbdT6TL2eP9v5ATfZp6WmA@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-31615@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 1675 bytes --]
There is an updated pull request by sgn against master on the void-packages repository
https://github.com/sgn/void-packages cmake-less-cursed-and-man-and-update
https://github.com/void-linux/void-packages/pull/31615
cmake less cursed template, ship manpages, switch GUI to Qt6, and update
<!-- Mark items with [x] where applicable -->
Not Tested.
#### General
- [ ] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)
#### Have the results of the proposed changes been tested?
- [ ] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR
<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
-->
<!--
#### Does it build and run successfully?
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [ ] I built this PR locally for my native architecture, (ARCH-LIBC)
- [ ] I built this PR locally for these architectures (if supported. mark crossbuilds):
- [ ] aarch64-musl
- [ ] armv7l
- [ ] armv6l-musl
-->
A patch file from https://github.com/void-linux/void-packages/pull/31615.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-cmake-less-cursed-and-man-and-update-31615.patch --]
[-- Type: text/x-diff, Size: 10508 bytes --]
From 2c1b0be7a631846e069c9271ba58a1c40ff6fb74 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx@gmail.com>
Date: Tue, 22 Jun 2021 22:41:53 +0700
Subject: [PATCH 1/6] build-style/cmake: only depends on cmake for non-cmake
package
* In the next change, we will remove it from cmake template entirely
---
common/environment/build-style/cmake.sh | 4 +++-
srcpkgs/cmake/template | 1 +
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/common/environment/build-style/cmake.sh b/common/environment/build-style/cmake.sh
index c2c0c76c8efc..19b8f35a01da 100644
--- a/common/environment/build-style/cmake.sh
+++ b/common/environment/build-style/cmake.sh
@@ -1,5 +1,7 @@
if [ "$CHROOT_READY" ]; then
- hostmakedepends+=" cmake"
+ if [ "$pkgname" != cmake ]; then
+ hostmakedepends+=" cmake"
+ fi
if [ "${make_cmd:-ninja}" = ninja ]; then
hostmakedepends+=" ninja"
fi
diff --git a/srcpkgs/cmake/template b/srcpkgs/cmake/template
index 5d3308f93b5d..9da71ccd1a9f 100644
--- a/srcpkgs/cmake/template
+++ b/srcpkgs/cmake/template
@@ -20,6 +20,7 @@ replaces="cmake-bootstrap>=0"
if [ "$CROSS_BUILD" ]; then
build_style=cmake
+ hostmakedepends+=" cmake"
configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
-DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1"
fi
From 9f8d6d7d3c004788c69597e1d6788b6818b93106 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx@gmail.com>
Date: Tue, 22 Jun 2021 22:57:44 +0700
Subject: [PATCH 2/6] cmake: always built with cmake build-style
Less cursed template (changed build-style for cross-compiling).
---
.../patches/no-run-cmake-bootstrap.patch | 13 +++++++
srcpkgs/cmake/template | 38 ++++++++++++++-----
2 files changed, 41 insertions(+), 10 deletions(-)
create mode 100644 srcpkgs/cmake/patches/no-run-cmake-bootstrap.patch
diff --git a/srcpkgs/cmake/patches/no-run-cmake-bootstrap.patch b/srcpkgs/cmake/patches/no-run-cmake-bootstrap.patch
new file mode 100644
index 000000000000..4b41aea2450b
--- /dev/null
+++ b/srcpkgs/cmake/patches/no-run-cmake-bootstrap.patch
@@ -0,0 +1,13 @@
+We will run cmake ourselves with our flags
+Index: cmake-3.20.3/bootstrap
+===================================================================
+--- cmake-3.20.3.orig/bootstrap
++++ cmake-3.20.3/bootstrap
+@@ -1968,6 +1968,7 @@ export CFLAGS
+ export CXXFLAGS
+ export LDFLAGS
+
++exit 0
+ # Run bootstrap CMake to configure real CMake
+ cmake_options="-DCMAKE_BOOTSTRAP=1"
+ if test -n "${cmake_verbose}"; then
diff --git a/srcpkgs/cmake/template b/srcpkgs/cmake/template
index 9da71ccd1a9f..87a1cde8048d 100644
--- a/srcpkgs/cmake/template
+++ b/srcpkgs/cmake/template
@@ -1,11 +1,12 @@
# Template file for 'cmake'
+# FIXME: cmake is being rebuilt on do_install
pkgname=cmake
version=3.20.3
revision=1
-build_style=configure
-configure_args="--prefix=/usr --mandir=/share/man --docdir=/share/doc/cmake
- --system-libs ${XBPS_MAKEJOBS:+--parallel=$XBPS_MAKEJOBS}"
-make_check_target=test
+build_style=cmake
+cmake_builddir=build
+configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
+ -DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1"
hostmakedepends="gcc-fortran"
makedepends="expat-devel libarchive-devel libcurl-devel libuv-devel
ncurses-devel rhash-devel jsoncpp-devel"
@@ -18,12 +19,29 @@ distfiles="https://www.cmake.org/files/v${version%.*}/${pkgname}-${version}.tar.
checksum=4d008ac3461e271fcfac26a05936f77fc7ab64402156fb371d41284851a651b8
replaces="cmake-bootstrap>=0"
-if [ "$CROSS_BUILD" ]; then
- build_style=cmake
- hostmakedepends+=" cmake"
- configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
- -DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1"
-fi
+# XXX: cmake is broken if cmake was built with -GNinja
+# https://bugs.gentoo.org/596460
+export CMAKE_GENERATOR="Unix Makefiles"
+make_cmd=make
+
+pre_configure() {
+ local f
+ mkdir -p $cmake_builddir
+ cd $cmake_builddir
+ CC="$CC_FOR_BUILD" CFLAGS="$CFLAGS_FOR_BUILD" \
+ CXX="$CXX_FOR_BUILD" CXXFLAGS="$CXXFLAGS_FOR_BUILD" \
+ LD="$LD_FOR_BUILD" LDFLAGS="$LDFLAGS_FOR_BUILD" \
+ ../bootstrap --no-system-libs \
+ ${XBPS_MAKEJOBS:+--parallel=$XBPS_MAKEJOBS}
+ # Make sure build directory is clean
+ for f in *; do
+ if [ "$f" != Bootstrap.cmk ]; then
+ return 1
+ fi
+ done
+ cd ${wrksrc}
+ PATH="${wrksrc}/$cmake_builddir/Bootstrap.cmk:$PATH"
+}
post_install() {
rm -rf ${DESTDIR}/usr/share/doc/cmake
From 4c0a8044511ead3cc6b1b806b598409d845e1da4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx@gmail.com>
Date: Tue, 22 Jun 2021 23:15:07 +0700
Subject: [PATCH 3/6] cmake: build man-pages
---
srcpkgs/cmake/template | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/cmake/template b/srcpkgs/cmake/template
index 87a1cde8048d..7f346c952257 100644
--- a/srcpkgs/cmake/template
+++ b/srcpkgs/cmake/template
@@ -2,12 +2,14 @@
# FIXME: cmake is being rebuilt on do_install
pkgname=cmake
version=3.20.3
-revision=1
+revision=2
build_style=cmake
cmake_builddir=build
configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
+ -DSPHINX_MAN=1 -DCMAKE_MAN_DIR=/share/man
+ -DCMAKE_SKIP_BOOTSTRAP_TEST=1 -DCMAKE_SKIP_RPATH=1
-DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1"
-hostmakedepends="gcc-fortran"
+hostmakedepends="gcc-fortran python3-Sphinx"
makedepends="expat-devel libarchive-devel libcurl-devel libuv-devel
ncurses-devel rhash-devel jsoncpp-devel"
checkdepends="pax pkg-config git"
From 0314f5692647b8b28607086c4350b8eaa806a993 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx@gmail.com>
Date: Tue, 22 Jun 2021 23:19:40 +0700
Subject: [PATCH 4/6] cmake-gui: build with Qt6
---
srcpkgs/cmake-gui/template | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/srcpkgs/cmake-gui/template b/srcpkgs/cmake-gui/template
index a3c6dbf3cb02..13a660baefd6 100644
--- a/srcpkgs/cmake-gui/template
+++ b/srcpkgs/cmake-gui/template
@@ -1,15 +1,15 @@
# Template file for 'cmake-gui'
pkgname=cmake-gui
version=3.20.3
-revision=1
+revision=2
wrksrc="cmake-${version}"
build_style=cmake
configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
- -DBUILD_QtDialog=ON -DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1
- -DCMake_GUI_DISTRIBUTE_WITH_Qt_LGPL=3"
-hostmakedepends="qt5-devel"
+ -DSPHINX_MAN=1 -DCMAKE_MAN_DIR=/share/man -DQT_HOST_PATH=/usr
+ -DBUILD_QtDialog=ON -DCMAKE_USE_SYSTEM_LIBRARIES=ON -DKWSYS_LFS_WORKS=1"
+hostmakedepends="qt6-base-devel python3-Sphinx"
makedepends="jsoncpp-devel libarchive-devel libcurl-devel libuv-devel
- ncurses-devel qt5-devel rhash-devel"
+ ncurses-devel qt6-base-devel rhash-devel"
depends="desktop-file-utils shared-mime-info cmake>=${version}"
checkdepends="pax pkg-config"
short_desc="Cross-platform, open-source build system - Qt GUI"
@@ -27,6 +27,7 @@ make_cmd=make
do_install() {
# We are only interested in cmake-gui.
vbin build/bin/cmake-gui
+ vman build/Utilities/Sphinx/man/cmake-gui.1
for res in 32 64 128 ; do
vinstall Source/QtDialog/CMakeSetup${res}.png 0644 \
From c448ea9fb248a7f6d3a70b53f9786d9352def10e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx@gmail.com>
Date: Tue, 22 Jun 2021 23:25:53 +0700
Subject: [PATCH 5/6] cmake: update to 3.20.5.
---
srcpkgs/cmake/template | 21 +++++++++++----------
1 file changed, 11 insertions(+), 10 deletions(-)
diff --git a/srcpkgs/cmake/template b/srcpkgs/cmake/template
index 7f346c952257..7ec873cb2afd 100644
--- a/srcpkgs/cmake/template
+++ b/srcpkgs/cmake/template
@@ -1,10 +1,9 @@
# Template file for 'cmake'
# FIXME: cmake is being rebuilt on do_install
pkgname=cmake
-version=3.20.3
-revision=2
+version=3.20.5
+revision=1
build_style=cmake
-cmake_builddir=build
configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
-DSPHINX_MAN=1 -DCMAKE_MAN_DIR=/share/man
-DCMAKE_SKIP_BOOTSTRAP_TEST=1 -DCMAKE_SKIP_RPATH=1
@@ -18,7 +17,7 @@ maintainer="Đoàn Trần Công Danh <congdanhqx@gmail.com>"
license="BSD-3-Clause, ICU"
homepage="https://www.cmake.org"
distfiles="https://www.cmake.org/files/v${version%.*}/${pkgname}-${version}.tar.gz"
-checksum=4d008ac3461e271fcfac26a05936f77fc7ab64402156fb371d41284851a651b8
+checksum=12c8040ef5c6f1bc5b8868cede16bb7926c18980f59779e299ab52cbc6f15bb0
replaces="cmake-bootstrap>=0"
# XXX: cmake is broken if cmake was built with -GNinja
@@ -26,13 +25,15 @@ replaces="cmake-bootstrap>=0"
export CMAKE_GENERATOR="Unix Makefiles"
make_cmd=make
+if [ "$CROSS_BUILD" ]; then
+ hostmakedepends+=" cmake"
+fi
+
pre_configure() {
local f
- mkdir -p $cmake_builddir
- cd $cmake_builddir
- CC="$CC_FOR_BUILD" CFLAGS="$CFLAGS_FOR_BUILD" \
- CXX="$CXX_FOR_BUILD" CXXFLAGS="$CXXFLAGS_FOR_BUILD" \
- LD="$LD_FOR_BUILD" LDFLAGS="$LDFLAGS_FOR_BUILD" \
+ [ ! "$CROSS_BUILD" ] || return 0
+ mkdir -p build
+ cd build
../bootstrap --no-system-libs \
${XBPS_MAKEJOBS:+--parallel=$XBPS_MAKEJOBS}
# Make sure build directory is clean
@@ -42,7 +43,7 @@ pre_configure() {
fi
done
cd ${wrksrc}
- PATH="${wrksrc}/$cmake_builddir/Bootstrap.cmk:$PATH"
+ PATH="${wrksrc}/build/Bootstrap.cmk:$PATH"
}
post_install() {
From 982bb23d2b80649851cf282888ade7b51219ac28 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
<congdanhqx@gmail.com>
Date: Tue, 22 Jun 2021 23:28:01 +0700
Subject: [PATCH 6/6] cmake-gui: update to 3.20.5.
---
srcpkgs/cmake-gui/template | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/srcpkgs/cmake-gui/template b/srcpkgs/cmake-gui/template
index 13a660baefd6..11e2fa7b809d 100644
--- a/srcpkgs/cmake-gui/template
+++ b/srcpkgs/cmake-gui/template
@@ -1,7 +1,7 @@
# Template file for 'cmake-gui'
pkgname=cmake-gui
-version=3.20.3
-revision=2
+version=3.20.5
+revision=1
wrksrc="cmake-${version}"
build_style=cmake
configure_args="-DCMAKE_DOC_DIR=/share/doc/cmake
@@ -17,7 +17,7 @@ maintainer="Đoàn Trần Công Danh <congdanhqx@gmail.com>"
license="BSD-3-Clause"
homepage="https://www.cmake.org"
distfiles="https://www.cmake.org/files/v${version%.*}/cmake-${version}.tar.gz"
-checksum=4d008ac3461e271fcfac26a05936f77fc7ab64402156fb371d41284851a651b8
+checksum=12c8040ef5c6f1bc5b8868cede16bb7926c18980f59779e299ab52cbc6f15bb0
# XXX: cmake is broken if cmake was built with -GNinja
# https://bugs.gentoo.org/596460
next prev parent reply other threads:[~2021-06-28 15:33 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-22 16:39 [PR PATCH] " sgn
2021-06-23 0:52 ` [PR REVIEW] " ericonr
2021-06-23 0:52 ` ericonr
2021-06-23 0:53 ` sgn
2021-06-23 0:55 ` sgn
2021-06-28 15:33 ` sgn [this message]
2021-07-02 0:14 ` [PR PATCH] [Updated] " sgn
2021-07-02 0:28 ` [PR PATCH] [Merged]: " sgn
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210628153323.xs9TQl1L3z9hiB9OUPj6nVbdT6TL2eP9v5ATfZp6WmA@z \
--to=sgn@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).