[arch-commits] Commit in fmt/trunk (PKGBUILD dont-install-doctrees.patch)

Jelle van der Waa jelle at archlinux.org
Sat May 30 18:39:32 UTC 2020


    Date: Saturday, May 30, 2020 @ 18:39:31
  Author: jelle
Revision: 387921

Make fmt reproducible by not installing sphinx cached files

Added:
  fmt/trunk/dont-install-doctrees.patch
Modified:
  fmt/trunk/PKGBUILD

-----------------------------+
 PKGBUILD                    |   13 ++++++++++---
 dont-install-doctrees.patch |   24 ++++++++++++++++++++++++
 2 files changed, 34 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2020-05-30 18:33:52 UTC (rev 387920)
+++ PKGBUILD	2020-05-30 18:39:31 UTC (rev 387921)
@@ -3,7 +3,7 @@
 
 pkgname=fmt
 pkgver=6.2.1
-pkgrel=2
+pkgrel=3
 pkgdesc='Open-source formatting library for C++'
 arch=(x86_64)
 url=https://fmt.dev
@@ -19,9 +19,10 @@
   python-virtualenv
 )
 provides=(libfmt.so)
-source=(git+https://github.com/fmtlib/fmt.git#tag=19bd751020a1f3c3363b2eb67a039852f139a8d3)
-sha256sums=(SKIP)
+source=(git+https://github.com/fmtlib/fmt.git#tag=19bd751020a1f3c3363b2eb67a039852f139a8d3
+        dont-install-doctrees.patch) # https://github.com/fmtlib/fmt/commit/8f2b5fe74d34ba8bb20a362a4daa6cc5a99a2010
 
+
 pkgver() {
   cd fmt
 
@@ -31,6 +32,10 @@
 prepare() {
   npm install less less-plugin-clean-css
   sed "s/'lessc',/'npx', 'lessc',/" -i fmt/doc/build.py
+
+  # Don't install sphinx cache doctrees directory
+  cd fmt
+  patch -Np1 -i ${srcdir}/dont-install-doctrees.patch
 }
 
 build() {
@@ -54,3 +59,5 @@
 }
 
 # vim: ts=2 sw=2 et:
+md5sums=('SKIP'
+         'f29b10877482313f98456cc2674c0c37')

Added: dont-install-doctrees.patch
===================================================================
--- dont-install-doctrees.patch	                        (rev 0)
+++ dont-install-doctrees.patch	2020-05-30 18:39:31 UTC (rev 387921)
@@ -0,0 +1,24 @@
+From 8f2b5fe74d34ba8bb20a362a4daa6cc5a99a2010 Mon Sep 17 00:00:00 2001
+From: Jelle van der Waa <jelle at vdwaa.nl>
+Date: Fri, 29 May 2020 23:19:16 +0200
+Subject: [PATCH] Don't install sphinx cache files
+
+When building documentation sphinx creates cached files in the .doctrees
+directory and aren't required for viewing documentation only for
+building. As added benefit this makes fmt reprodcubile as the cached
+files are different when the build environment is varied.
+---
+ doc/CMakeLists.txt | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt
+index f3dae606e..108aa71e8 100644
+--- a/doc/CMakeLists.txt
++++ b/doc/CMakeLists.txt
+@@ -9,4 +9,5 @@ add_custom_target(doc
+   SOURCES api.rst syntax.rst usage.rst build.py conf.py _templates/layout.html)
+ 
+ install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/
+-        DESTINATION share/doc/fmt OPTIONAL)
++        DESTINATION share/doc/fmt OPTIONAL
++        PATTERN ".doctrees" EXCLUDE)



More information about the arch-commits mailing list