From baf766a7ff9db45c707b4539176f2143fbd90efd Mon Sep 17 00:00:00 2001 From: Danny Milosavljevic Date: Fri, 1 Feb 2019 17:06:25 +0100 Subject: gnu: mrustc: Fix deserialization bug in communication with the procedural macro compiler plugin. * gnu/packages/patches/mrustc-0.8.0-fix-variable-length-integer-receiving.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/rust.scm (mrustc)[source]: Use it. Co-authored-by: Chris Marusich --- gnu/local.mk | 1 + 1 file changed, 1 insertion(+) (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index 37083ca916..4493470bb4 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1046,6 +1046,7 @@ dist_patch_DATA = \ %D%/packages/patches/mozjs38-tracelogger.patch \ %D%/packages/patches/mozjs38-version-detection.patch \ %D%/packages/patches/mrrescue-support-love-11.patch \ + %D%/packages/patches/mrustc-0.8.0-fix-variable-length-integer-receiving.patch \ %D%/packages/patches/mumble-1.2.19-abs.patch \ %D%/packages/patches/mumps-build-parallelism.patch \ %D%/packages/patches/mupen64plus-ui-console-notice.patch \ -- cgit v1.2.3 From 350b7f8a7441d7df89249b356299a843b9a18794 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Wed, 6 Mar 2019 16:00:12 +0100 Subject: gnu: valgrind: Update to 3.14.0. * gnu/packages/patches/valgrind-glibc-compat.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/valgrind.scm (valgrind): Update to 3.14.0. [supported-systems]: Add mips64el-linux. --- gnu/local.mk | 1 - gnu/packages/patches/valgrind-glibc-compat.patch | 18 ------------------ gnu/packages/valgrind.scm | 13 ++++--------- 3 files changed, 4 insertions(+), 28 deletions(-) delete mode 100644 gnu/packages/patches/valgrind-glibc-compat.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index eecace58c6..f51b9fbfe2 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1308,7 +1308,6 @@ dist_patch_DATA = \ %D%/packages/patches/upower-builddir.patch \ %D%/packages/patches/upx-fix-CVE-2017-15056.patch \ %D%/packages/patches/valgrind-enable-arm.patch \ - %D%/packages/patches/valgrind-glibc-compat.patch \ %D%/packages/patches/vboot-utils-fix-format-load-address.patch \ %D%/packages/patches/vboot-utils-fix-tests-show-contents.patch \ %D%/packages/patches/vboot-utils-skip-test-workbuf.patch \ diff --git a/gnu/packages/patches/valgrind-glibc-compat.patch b/gnu/packages/patches/valgrind-glibc-compat.patch deleted file mode 100644 index 4f8effd207..0000000000 --- a/gnu/packages/patches/valgrind-glibc-compat.patch +++ /dev/null @@ -1,18 +0,0 @@ -Fix build failure with glibc 2.26. - -Patch copied from upstream source repository: -https://sourceware.org/git/?p=valgrind.git;a=commit;h=2b5eab6a8db1b0487a3ad7fc4e7eeda6d3513626 - -diff --git a/memcheck/tests/linux/stack_changes.c b/memcheck/tests/linux/stack_changes.c -index a978fc2..7f97b90 100644 ---- a/memcheck/tests/linux/stack_changes.c -+++ b/memcheck/tests/linux/stack_changes.c -@@ -10,7 +10,7 @@ - // This test is checking the libc context calls (setcontext, etc.) and - // checks that Valgrind notices their stack changes properly. - --typedef struct ucontext mycontext; -+typedef ucontext_t mycontext; - - mycontext ctx1, ctx2, oldc; - int count; diff --git a/gnu/packages/valgrind.scm b/gnu/packages/valgrind.scm index 0a6206b3b1..9952fa1647 100644 --- a/gnu/packages/valgrind.scm +++ b/gnu/packages/valgrind.scm @@ -32,7 +32,7 @@ (define-public valgrind (package (name "valgrind") - (version "3.13.0") + (version "3.14.0") (source (origin (method url-fetch) (uri (list (string-append "http://www.valgrind.org/downloads" @@ -41,9 +41,8 @@ "/valgrind-" version ".tar.bz2"))) (sha256 (base32 - "0fqc3684grrbxwsic1rc5ryxzxmigzjx9p5vf3lxa37h0gpq0rnp")) - (patches (search-patches "valgrind-enable-arm.patch" - "valgrind-glibc-compat.patch")))) + "19ds42jwd89zrsjb94g7gizkkzipn8xik3xykrpcqxylxyzi2z03")) + (patches (search-patches "valgrind-enable-arm.patch")))) (build-system gnu-build-system) (outputs '("doc" ;16 MB "out")) @@ -79,8 +78,4 @@ tools. There are Valgrind tools that can automatically detect many memory management and threading bugs, and profile your programs in detail. You can also use Valgrind to build new tools.") - (license gpl2+) - - ;; Building VEX on mips64el-linux fails with "opcode not supported on this - ;; processor: mips3". - (supported-systems (delete "mips64el-linux" %supported-systems)))) + (license gpl2+))) -- cgit v1.2.3 From 0daf0efbe633d26bf51d8221573332d54c6bd55e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 5 Aug 2018 16:37:39 +0200 Subject: gnu: gcr: Update to 3.28.0. * gnu/packages/patches/gcr-disable-failing-tests.patch, gnu/packages/patches/gcr-fix-collection-tests-to-work-with-gpg-21.patch: Remove files. * gnu/local.mk (dist_patch_DATA): Remove patches. * gnu/packages/gnome.scm (gcr): Update to 3.28.0. [arguments]: Add phase "disable-failing-tests"; rewrite "pre-check" phase. [native-inputs]: Add libxml2. --- gnu/local.mk | 2 - gnu/packages/gnome.scm | 45 ++++---- .../patches/gcr-disable-failing-tests.patch | 126 --------------------- ...-fix-collection-tests-to-work-with-gpg-21.patch | 31 ----- 4 files changed, 26 insertions(+), 178 deletions(-) delete mode 100644 gnu/packages/patches/gcr-disable-failing-tests.patch delete mode 100644 gnu/packages/patches/gcr-fix-collection-tests-to-work-with-gpg-21.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index f51b9fbfe2..45fa7d2007 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -794,8 +794,6 @@ dist_patch_DATA = \ %D%/packages/patches/gcc-6-source-date-epoch-1.patch \ %D%/packages/patches/gcc-6-source-date-epoch-2.patch \ %D%/packages/patches/gcc-8-strmov-store-file-names.patch \ - %D%/packages/patches/gcr-disable-failing-tests.patch \ - %D%/packages/patches/gcr-fix-collection-tests-to-work-with-gpg-21.patch \ %D%/packages/patches/gd-CVE-2018-5711.patch \ %D%/packages/patches/gd-CVE-2018-1000222.patch \ %D%/packages/patches/gd-CVE-2019-6977.patch \ diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 4d4c831448..aa6e95456a 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -587,36 +587,43 @@ and keep up to date translations of documentation.") (define-public gcr (package (name "gcr") - (version "3.20.0") + (version "3.28.0") (source (origin - (method url-fetch) - (uri (string-append "mirror://gnome/sources/" name "/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "0ydk9dzxx6snxza7j5ps8x932hbr3x1b8hhcaqjq4w4admi2qmwh")) - (patches - (search-patches "gcr-disable-failing-tests.patch" - "gcr-fix-collection-tests-to-work-with-gpg-21.patch")))) + (method url-fetch) + (uri (string-append "mirror://gnome/sources/" name "/" + (version-major+minor version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "02xgky22xgvhgd525khqh64l5i21ca839fj9jzaqdi3yvb8pbq8m")))) (build-system gnu-build-system) (arguments - '(#:phases (modify-phases %standard-phases - (add-before - 'check 'pre-check - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "build/tap-driver" - (("/usr/bin/env python") (which "python")))))))) + '(#:phases + (modify-phases %standard-phases + ;; These fail because /var/lib/dbus/machine-id is not present in the + ;; build environment. + (add-after 'unpack 'disable-failing-tests + (lambda _ + (substitute* "gcr/test-system-prompt.c" + (("g_test_add") "//") + (("return.*") "return 0;")) + #t)) + (add-before 'check 'pre-check + (lambda _ + ;; Some tests expect to write to $HOME. + (setenv "HOME" "/tmp") + #t))))) (inputs `(("dbus" ,dbus) - ("gnupg" ,gnupg) ;called as a child process during tests + ("gnupg" ,gnupg) ;called as a child process during tests ("libgcrypt" ,libgcrypt))) (native-inputs - `(("python" ,python-2) ;for tests + `(("python" ,python-2) ;for tests ("pkg-config" ,pkg-config) ("glib" ,glib "bin") ("gobject-introspection" ,gobject-introspection) ("intltool" ,intltool) + ("libxml2" ,libxml2) ("xsltproc" ,libxslt))) ;; mentioned in gck.pc, gcr.pc and gcr-ui.pc (propagated-inputs diff --git a/gnu/packages/patches/gcr-disable-failing-tests.patch b/gnu/packages/patches/gcr-disable-failing-tests.patch deleted file mode 100644 index 862c51faf0..0000000000 --- a/gnu/packages/patches/gcr-disable-failing-tests.patch +++ /dev/null @@ -1,126 +0,0 @@ -This patch removes a group of tests that fail because /var/lib/dbus/machine-id -is not present in the build environment. - ---- gcr-3.20.0.old/Makefile.in 2017-07-03 18:05:10.742595317 -0400 -+++ gcr-3.20.0/Makefile.in 2017-07-03 18:08:26.379565428 -0400 -@@ -482,8 +482,7 @@ - test-openssh$(EXEEXT) test-secure-memory$(EXEEXT) \ - test-trust$(EXEEXT) test-parser$(EXEEXT) test-record$(EXEEXT) \ - test-memory-icon$(EXEEXT) test-gnupg-key$(EXEEXT) \ -- test-gnupg-collection$(EXEEXT) test-gnupg-process$(EXEEXT) \ -- test-system-prompt$(EXEEXT) -+ test-gnupg-collection$(EXEEXT) test-gnupg-process$(EXEEXT) - @WITH_GTK_TRUE@am__EXEEXT_4 = frob-certificate$(EXEEXT) \ - @WITH_GTK_TRUE@ frob-combo-selector$(EXEEXT) \ - @WITH_GTK_TRUE@ frob-gnupg-selector$(EXEEXT) \ -@@ -882,14 +881,6 @@ - am_test_symkey_OBJECTS = egg/test-symkey.$(OBJEXT) - test_symkey_OBJECTS = $(am_test_symkey_OBJECTS) - test_symkey_DEPENDENCIES = $(am__DEPENDENCIES_4) --am_test_system_prompt_OBJECTS = \ -- gcr/test_system_prompt-test-system-prompt.$(OBJEXT) --test_system_prompt_OBJECTS = $(am_test_system_prompt_OBJECTS) --test_system_prompt_DEPENDENCIES = $(am__DEPENDENCIES_3) --test_system_prompt_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ -- $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ -- $(test_system_prompt_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ -- $(LDFLAGS) -o $@ - am_test_trust_OBJECTS = gcr/test_trust-test-trust.$(OBJEXT) - test_trust_OBJECTS = $(am_test_trust_OBJECTS) - test_trust_DEPENDENCIES = $(am__DEPENDENCIES_3) -@@ -974,8 +965,7 @@ - $(test_secret_exchange_SOURCES) $(test_secure_memory_SOURCES) \ - $(test_simple_certificate_SOURCES) \ - $(test_subject_public_key_SOURCES) $(test_symkey_SOURCES) \ -- $(test_system_prompt_SOURCES) $(test_trust_SOURCES) \ -- $(test_util_SOURCES) -+ $(test_trust_SOURCES) $(test_util_SOURCES) - DIST_SOURCES = $(libegg_asn1x_la_SOURCES) $(libegg_hex_la_SOURCES) \ - $(libegg_secmem_la_SOURCES) $(libegg_test_la_SOURCES) \ - $(libegg_la_SOURCES) $(libgck_@GCK_MAJOR@_la_SOURCES) \ -@@ -1016,8 +1006,7 @@ - $(test_secret_exchange_SOURCES) $(test_secure_memory_SOURCES) \ - $(test_simple_certificate_SOURCES) \ - $(test_subject_public_key_SOURCES) $(test_symkey_SOURCES) \ -- $(test_system_prompt_SOURCES) $(test_trust_SOURCES) \ -- $(test_util_SOURCES) -+ $(test_trust_SOURCES) $(test_util_SOURCES) - RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ -@@ -2117,8 +2106,7 @@ - test-memory-icon \ - test-gnupg-key \ - test-gnupg-collection \ -- test-gnupg-process \ -- test-system-prompt -+ test-gnupg-process - - test_certificate_SOURCES = gcr/test-certificate.c - test_certificate_CFLAGS = $(gcr_CFLAGS) -@@ -2171,9 +2159,6 @@ - test_subject_public_key_SOURCES = gcr/test-subject-public-key.c - test_subject_public_key_CFLAGS = $(gcr_CFLAGS) - test_subject_public_key_LDADD = $(gcr_LIBS) --test_system_prompt_SOURCES = gcr/test-system-prompt.c --test_system_prompt_CFLAGS = $(gcr_CFLAGS) --test_system_prompt_LDADD = $(gcr_LIBS) - test_trust_SOURCES = gcr/test-trust.c - test_trust_CFLAGS = $(gcr_CFLAGS) - test_trust_LDADD = $(gcr_LIBS) -@@ -3283,12 +3268,6 @@ - test-symkey$(EXEEXT): $(test_symkey_OBJECTS) $(test_symkey_DEPENDENCIES) $(EXTRA_test_symkey_DEPENDENCIES) - @rm -f test-symkey$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(test_symkey_OBJECTS) $(test_symkey_LDADD) $(LIBS) --gcr/test_system_prompt-test-system-prompt.$(OBJEXT): \ -- gcr/$(am__dirstamp) gcr/$(DEPDIR)/$(am__dirstamp) -- --test-system-prompt$(EXEEXT): $(test_system_prompt_OBJECTS) $(test_system_prompt_DEPENDENCIES) $(EXTRA_test_system_prompt_DEPENDENCIES) -- @rm -f test-system-prompt$(EXEEXT) -- $(AM_V_CCLD)$(test_system_prompt_LINK) $(test_system_prompt_OBJECTS) $(test_system_prompt_LDADD) $(LIBS) - gcr/test_trust-test-trust.$(OBJEXT): gcr/$(am__dirstamp) \ - gcr/$(DEPDIR)/$(am__dirstamp) - -@@ -3446,7 +3425,6 @@ - @AMDEP_TRUE@@am__include@ @am__quote@gcr/$(DEPDIR)/test_secure_memory-test-secure-memory.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@gcr/$(DEPDIR)/test_simple_certificate-test-simple-certificate.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@gcr/$(DEPDIR)/test_subject_public_key-test-subject-public-key.Po@am__quote@ --@AMDEP_TRUE@@am__include@ @am__quote@gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@gcr/$(DEPDIR)/test_trust-test-trust.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@gcr/$(DEPDIR)/test_util-test-util.Po@am__quote@ - @AMDEP_TRUE@@am__include@ @am__quote@ui/$(DEPDIR)/frob_certificate-frob-certificate.Po@am__quote@ -@@ -4968,20 +4946,6 @@ - @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ - @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_subject_public_key_CFLAGS) $(CFLAGS) -c -o gcr/test_subject_public_key-test-subject-public-key.obj `if test -f 'gcr/test-subject-public-key.c'; then $(CYGPATH_W) 'gcr/test-subject-public-key.c'; else $(CYGPATH_W) '$(srcdir)/gcr/test-subject-public-key.c'; fi` - --gcr/test_system_prompt-test-system-prompt.o: gcr/test-system-prompt.c --@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_system_prompt_CFLAGS) $(CFLAGS) -MT gcr/test_system_prompt-test-system-prompt.o -MD -MP -MF gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Tpo -c -o gcr/test_system_prompt-test-system-prompt.o `test -f 'gcr/test-system-prompt.c' || echo '$(srcdir)/'`gcr/test-system-prompt.c --@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Tpo gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Po --@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='gcr/test-system-prompt.c' object='gcr/test_system_prompt-test-system-prompt.o' libtool=no @AMDEPBACKSLASH@ --@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ --@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_system_prompt_CFLAGS) $(CFLAGS) -c -o gcr/test_system_prompt-test-system-prompt.o `test -f 'gcr/test-system-prompt.c' || echo '$(srcdir)/'`gcr/test-system-prompt.c -- --gcr/test_system_prompt-test-system-prompt.obj: gcr/test-system-prompt.c --@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_system_prompt_CFLAGS) $(CFLAGS) -MT gcr/test_system_prompt-test-system-prompt.obj -MD -MP -MF gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Tpo -c -o gcr/test_system_prompt-test-system-prompt.obj `if test -f 'gcr/test-system-prompt.c'; then $(CYGPATH_W) 'gcr/test-system-prompt.c'; else $(CYGPATH_W) '$(srcdir)/gcr/test-system-prompt.c'; fi` --@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Tpo gcr/$(DEPDIR)/test_system_prompt-test-system-prompt.Po --@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='gcr/test-system-prompt.c' object='gcr/test_system_prompt-test-system-prompt.obj' libtool=no @AMDEPBACKSLASH@ --@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ --@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_system_prompt_CFLAGS) $(CFLAGS) -c -o gcr/test_system_prompt-test-system-prompt.obj `if test -f 'gcr/test-system-prompt.c'; then $(CYGPATH_W) 'gcr/test-system-prompt.c'; else $(CYGPATH_W) '$(srcdir)/gcr/test-system-prompt.c'; fi` -- - gcr/test_trust-test-trust.o: gcr/test-trust.c - @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_trust_CFLAGS) $(CFLAGS) -MT gcr/test_trust-test-trust.o -MD -MP -MF gcr/$(DEPDIR)/test_trust-test-trust.Tpo -c -o gcr/test_trust-test-trust.o `test -f 'gcr/test-trust.c' || echo '$(srcdir)/'`gcr/test-trust.c - @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) gcr/$(DEPDIR)/test_trust-test-trust.Tpo gcr/$(DEPDIR)/test_trust-test-trust.Po -@@ -5808,13 +5772,6 @@ - $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ - --log-file $$b.log --trs-file $$b.trs \ - $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ -- "$$tst" $(AM_TESTS_FD_REDIRECT) --test-system-prompt.log: test-system-prompt$(EXEEXT) -- @p='test-system-prompt$(EXEEXT)'; \ -- b='test-system-prompt'; \ -- $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ -- --log-file $$b.log --trs-file $$b.trs \ -- $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ - "$$tst" $(AM_TESTS_FD_REDIRECT) - .test.log: - @p='$<'; \ diff --git a/gnu/packages/patches/gcr-fix-collection-tests-to-work-with-gpg-21.patch b/gnu/packages/patches/gcr-fix-collection-tests-to-work-with-gpg-21.patch deleted file mode 100644 index 86a8ed1691..0000000000 --- a/gnu/packages/patches/gcr-fix-collection-tests-to-work-with-gpg-21.patch +++ /dev/null @@ -1,31 +0,0 @@ -This patch comes from Debian. - -https://bugzilla.gnome.org/show_bug.cgi?id=771052 -https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=835737 - ---- gcr-3.20.0.old/gcr/test-gnupg-collection.c 2017-06-29 14:26:33.810838197 -0400 -+++ gcr-3.20.0/gcr/test-gnupg-collection.c 2017-06-30 17:25:09.149383067 -0400 -@@ -115,6 +115,14 @@ - - g_object_unref (test->collection); - -+ /* remove potential gpg 2.1 extras, ignore any errors. */ -+ cmd = g_strdup_printf ("rm -rf %s/*.d", test->directory); -+ system(cmd); -+ g_free(cmd); -+ cmd = g_strdup_printf ("rm -f %s/.gpg-v21-migrated", test->directory); -+ system(cmd); -+ g_free(cmd); -+ - cmd = g_strdup_printf ("rm -f %s/*", test->directory); - g_spawn_check_exit_status (system (cmd), &error); - g_assert_no_error (error); -@@ -202,7 +210,7 @@ - GcrGnupgKey *key; - - _gcr_gnupg_collection_load_async (test->collection, NULL, on_async_ready, test); -- egg_test_wait_until (500); -+ egg_test_wait_until (2500); - g_assert (test->result); - _gcr_gnupg_collection_load_finish (test->collection, test->result, &error); - g_assert_no_error (error); -- cgit v1.2.3 From 9f3c6c8825e2935766ac5bc1880ed74f7fce48f4 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Mon, 6 Aug 2018 16:52:49 +0200 Subject: gnu: gnome-todo: Update to 3.28.1. * gnu/packages/gnome.scm (gnome-todo): Update to 3.28.1. * gnu/local.mk (dist_patch_DATA): Remove patch. * gnu/packages/patches/gnome-todo-libical-compat.patch: Remove file. --- gnu/local.mk | 1 - gnu/packages/gnome.scm | 5 ++--- gnu/packages/patches/gnome-todo-libical-compat.patch | 17 ----------------- 3 files changed, 2 insertions(+), 21 deletions(-) delete mode 100644 gnu/packages/patches/gnome-todo-libical-compat.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index 45fa7d2007..38fee9e4ea 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -838,7 +838,6 @@ dist_patch_DATA = \ %D%/packages/patches/gmp-arm-asm-nothumb.patch \ %D%/packages/patches/gmp-faulty-test.patch \ %D%/packages/patches/gnome-shell-theme.patch \ - %D%/packages/patches/gnome-todo-libical-compat.patch \ %D%/packages/patches/gnome-tweak-tool-search-paths.patch \ %D%/packages/patches/gnucash-fix-test-transaction-failure.patch \ %D%/packages/patches/gnutls-skip-trust-store-test.patch \ diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 6f84d60928..098b039605 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -6440,16 +6440,15 @@ desktop. It supports multiple calendars, month, week and year view.") (define-public gnome-todo (package (name "gnome-todo") - (version "3.26.2") + (version "3.28.1") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" (version-major+minor version) "/" name "-" version ".tar.xz")) - (patches (search-patches "gnome-todo-libical-compat.patch")) (sha256 (base32 - "106xx1w18pxjmj5k0k2qjzi6b3c3kaz7b5kyrpknykibnr401ff9")))) + "08ygqbib72jlf9y0a16k54zz51sncpq2wa18wp81v46q8301ymy7")))) (build-system meson-build-system) (arguments '(#:glib-or-gtk? #t diff --git a/gnu/packages/patches/gnome-todo-libical-compat.patch b/gnu/packages/patches/gnome-todo-libical-compat.patch deleted file mode 100644 index 34f2e254b2..0000000000 --- a/gnu/packages/patches/gnome-todo-libical-compat.patch +++ /dev/null @@ -1,17 +0,0 @@ -Fix compatibility with libical 3.0. - -Patch copied from Arch Linux: -https://git.archlinux.org/svntogit/packages.git/tree/trunk/gnome-todo-3.26.2-libical-3.0.patch?h=packages/gnome-todo - -diff -up gnome-todo-3.26.2/src/gtd-task.c.libical-3.0 gnome-todo-3.26.2/src/gtd-task.c ---- gnome-todo-3.26.2/src/gtd-task.c.libical-3.0 2017-11-08 14:53:53.484294926 +0100 -+++ gnome-todo-3.26.2/src/gtd-task.c 2017-11-08 14:53:57.208294874 +0100 -@@ -778,7 +778,7 @@ gtd_task_set_complete (GtdTask *task, - dt->minute = g_date_time_get_minute (now); - dt->second = g_date_time_get_seconds (now); - dt->is_date = 0; -- dt->is_utc = 1; -+ dt->zone = icaltimezone_get_utc_timezone (); - - /* convert timezone - * -- cgit v1.2.3 From 81382e3f6d4eb0261bf513a16be58d8d0b7373f2 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Fri, 15 Mar 2019 16:03:59 +0100 Subject: gnu: meson: Update to 0.50.0. * gnu/packages/build-tools.scm (meson): Update to 0.50.0. * gnu/packages/patches/at-spi2-core-meson-compat.patch, gnu/packages/patches/totem-meson-compat.patch: New files. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/gnome.scm (totem)[source](patches): Add totem-meson.compat.patch. * gnu/packages/gtk.scm (at-spi2-core)[source](patches): New field. --- gnu/local.mk | 2 ++ gnu/packages/build-tools.scm | 4 ++-- gnu/packages/gnome.scm | 3 ++- gnu/packages/gtk.scm | 1 + gnu/packages/patches/at-spi2-core-meson-compat.patch | 18 ++++++++++++++++++ gnu/packages/patches/totem-meson-compat.patch | 14 ++++++++++++++ 6 files changed, 39 insertions(+), 3 deletions(-) create mode 100644 gnu/packages/patches/at-spi2-core-meson-compat.patch create mode 100644 gnu/packages/patches/totem-meson-compat.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index eb1b5d223d..1d73189b17 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -652,6 +652,7 @@ dist_patch_DATA = \ %D%/packages/patches/apr-skip-getservbyname-test.patch \ %D%/packages/patches/aria2-CVE-2019-3500.patch \ %D%/packages/patches/aspell-default-dict-dir.patch \ + %D%/packages/patches/at-spi2-core-meson-compat.patch \ %D%/packages/patches/ath9k-htc-firmware-binutils.patch \ %D%/packages/patches/ath9k-htc-firmware-gcc.patch \ %D%/packages/patches/ath9k-htc-firmware-objcopy.patch \ @@ -1287,6 +1288,7 @@ dist_patch_DATA = \ %D%/packages/patches/tk-find-library.patch \ %D%/packages/patches/ttf2eot-cstddef.patch \ %D%/packages/patches/ttfautohint-source-date-epoch.patch \ + %D%/packages/patches/totem-meson-compat.patch \ %D%/packages/patches/totem-meson-easy-codec.patch \ %D%/packages/patches/tuxpaint-stamps-path.patch \ %D%/packages/patches/twinkle-include-qregexpvalidator.patch \ diff --git a/gnu/packages/build-tools.scm b/gnu/packages/build-tools.scm index 7031ed8ea3..71b1756d3b 100644 --- a/gnu/packages/build-tools.scm +++ b/gnu/packages/build-tools.scm @@ -160,7 +160,7 @@ files and generates build instructions for the Ninja build system.") (define-public meson (package (name "meson") - (version "0.49.2") + (version "0.50.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/mesonbuild/meson/" @@ -168,7 +168,7 @@ files and generates build instructions for the Ninja build system.") version ".tar.gz")) (sha256 (base32 - "1z89f71r29laywx75bamjakybv9653wz0vd2l4xhvqy1dqr197zg")))) + "07q2wz23wjfk8z66mli1cc9as0ycjp5f39fd4awny82qv8nw86ra")))) (build-system python-build-system) (arguments `(;; FIXME: Tests require many additional inputs, a fix for the RUNPATH diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 28048f8da2..c4521cebb9 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -3766,7 +3766,8 @@ for application developers.") (sha256 (base32 "1llyisls3pzf5bwkpxyfyxc2d3gpa09n5pjy7qsjdqrp3ya4k36g")) - (patches (search-patches "totem-meson-easy-codec.patch")))) + (patches (search-patches "totem-meson-easy-codec.patch" + "totem-meson-compat.patch")))) (build-system meson-build-system) (native-inputs `(("pkg-config" ,pkg-config) diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index c790bd8e40..83ed8407da 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -561,6 +561,7 @@ in the GNOME project.") (uri (string-append "mirror://gnome/sources/" name "/" (version-major+minor version) "/" name "-" version ".tar.xz")) + (patches (search-patches "at-spi2-core-meson-compat.patch")) (sha256 (base32 "083j1v7kdjrpjsv1b9dl3d8xqj39jyp4cfn8i9gbbm7q2g93b923")))) diff --git a/gnu/packages/patches/at-spi2-core-meson-compat.patch b/gnu/packages/patches/at-spi2-core-meson-compat.patch new file mode 100644 index 0000000000..168a31b4ed --- /dev/null +++ b/gnu/packages/patches/at-spi2-core-meson-compat.patch @@ -0,0 +1,18 @@ +Fix build with Meson 0.50.0 and above. + +Taken from upstream repository: +https://gitlab.gnome.org/GNOME/at-spi2-core/commit/44a812ea51223d82f21a098a2d45fcc5c329ce7a + +diff --git a/atspi/meson.build b/atspi/meson.build +index b7a9357df1c4857dffa2ec123cd3073e67a07fea..2a6915d76202dabf923b50e6a8b85cbb83cb43d0 100644 +--- a/atspi/meson.build ++++ b/atspi/meson.build +@@ -57,7 +57,7 @@ atspi_headers = [ + + atspi_includedir = join_paths(get_option('prefix'), get_option('includedir'), 'at-spi-2.0', 'atspi') + +-install_headers(atspi_headers, subdir: atspi_includedir) ++install_headers(atspi_headers, install_dir: atspi_includedir) + + atspi_enums = gnome.mkenums('atspi-enum-types', + sources: [ 'atspi-constants.h', 'atspi-types.h' ], diff --git a/gnu/packages/patches/totem-meson-compat.patch b/gnu/packages/patches/totem-meson-compat.patch new file mode 100644 index 0000000000..8557908dd0 --- /dev/null +++ b/gnu/packages/patches/totem-meson-compat.patch @@ -0,0 +1,14 @@ +Fix an error that occurs with Meson 0.50.0 and later: +"ERROR: Subdir keyword must not be an absolute path". + +--- a/src/meson.build 2019-03-15 00:10:26.882293850 +0100 ++++ b/src/meson.build 2019-03-15 00:10:54.312197229 +0100 +@@ -82,7 +82,7 @@ + + install_headers( + headers, +- subdir: join_paths(totem_includedir, totem_api_path) ++ install_dir: join_paths(totem_includedir, totem_api_path) + ) + + libtotem_player_sources = files( -- cgit v1.2.3 From 0fa50555975dcad5dc2c886d1c496b2335be6a28 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Wed, 27 Mar 2019 18:05:05 +0100 Subject: gnu: texlive-bin: Adopt LFS patch. The origin disappeared, and the new revision does not include all the Poppler fixes. Adjust the package to take Arch's Poppler patches instead. * gnu/packages/patches/texlive-bin-CVE-2018-17407.patch: New file. * gnu/packages/patches/texlive-bin-pdftex-poppler-compat.patch, gnu/packages/patches/texlive-bin-xetex-poppler-compat.patch: Delete files. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/tex.scm (texlive-bin)[source](patches): Likewise. [arguments]: Likewise. --- gnu/local.mk | 3 +- .../patches/texlive-bin-CVE-2018-17407.patch | 249 +++++++++++++++++++++ .../texlive-bin-pdftex-poppler-compat.patch | 188 ---------------- .../patches/texlive-bin-xetex-poppler-compat.patch | 31 --- gnu/packages/tex.scm | 36 +-- 5 files changed, 269 insertions(+), 238 deletions(-) create mode 100644 gnu/packages/patches/texlive-bin-CVE-2018-17407.patch delete mode 100644 gnu/packages/patches/texlive-bin-pdftex-poppler-compat.patch delete mode 100644 gnu/packages/patches/texlive-bin-xetex-poppler-compat.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index ec82877970..1844fbd404 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1276,9 +1276,8 @@ dist_patch_DATA = \ %D%/packages/patches/teeworlds-use-latest-wavpack.patch \ %D%/packages/patches/texinfo-perl-compat.patch \ %D%/packages/patches/texinfo-5-perl-compat.patch \ + %D%/packages/patches/texlive-bin-CVE-2018-17407.patch \ %D%/packages/patches/texlive-bin-luatex-poppler-compat.patch \ - %D%/packages/patches/texlive-bin-pdftex-poppler-compat.patch \ - %D%/packages/patches/texlive-bin-xetex-poppler-compat.patch \ %D%/packages/patches/telegram-purple-adjust-test.patch \ %D%/packages/patches/texi2html-document-encoding.patch \ %D%/packages/patches/texi2html-i18n.patch \ diff --git a/gnu/packages/patches/texlive-bin-CVE-2018-17407.patch b/gnu/packages/patches/texlive-bin-CVE-2018-17407.patch new file mode 100644 index 0000000000..63646d420c --- /dev/null +++ b/gnu/packages/patches/texlive-bin-CVE-2018-17407.patch @@ -0,0 +1,249 @@ +This patch adds support for newer versions of Poppler and some upstream +TexLive fixes, including one for CVE-2018-17407. + +It is taken from Linux From Scratch: +. + +Submitted By: Ken Moffat +Date: 2018-12-26 +Initial Package Version: 20180414 +Upstream Status: Applied +Origin: Upstream +Description: Two fixes, cherry-picked from svn plus a CVE fix. +I have removed the partial fixes for various system versions of poppler. + +r47469 Fix segfault in dvipdfm-x (XeTeX) on 1/2/4-bit transparent indexed PNGs. + +r47477 Fix a ptex regression for discontinuous kinsoku table. + +Also, via fedora (I got lost in svn) a critical fix for CVE-2018-17407 + +"A buffer overflow in the handling of Type 1 fonts allows arbitrary code +execution when a malicious font is loaded by one of the vulnerable tools: +pdflatex, pdftex, dvips, or luatex." + +diff -Naur a/texk/dvipdfm-x/pngimage.c b/texk/dvipdfm-x/pngimage.c +--- a/texk/dvipdfm-x/pngimage.c 2018-02-17 08:41:35.000000000 +0000 ++++ b/texk/dvipdfm-x/pngimage.c 2018-10-09 01:52:01.648670875 +0100 +@@ -964,12 +964,16 @@ + png_bytep trans; + int num_trans; + png_uint_32 i; ++ png_byte bpc, mask, shift; + + if (!png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) || + !png_get_tRNS(png_ptr, info_ptr, &trans, &num_trans, NULL)) { + WARN("%s: PNG does not have valid tRNS chunk but tRNS is requested.", PNG_DEBUG_STR); + return NULL; + } ++ bpc = png_get_bit_depth(png_ptr, info_ptr); ++ mask = 0xff >> (8 - bpc); ++ shift = 8 - bpc; + + smask = pdf_new_stream(STREAM_COMPRESS); + dict = pdf_stream_dict(smask); +@@ -981,7 +985,8 @@ + pdf_add_dict(dict, pdf_new_name("ColorSpace"), pdf_new_name("DeviceGray")); + pdf_add_dict(dict, pdf_new_name("BitsPerComponent"), pdf_new_number(8)); + for (i = 0; i < width*height; i++) { +- png_byte idx = image_data_ptr[i]; ++ /* data is packed for 1/2/4 bpc formats, msb first */ ++ png_byte idx = (image_data_ptr[bpc * i / 8] >> (shift - bpc * i % 8)) & mask; + smask_data_ptr[i] = (idx < num_trans) ? trans[idx] : 0xff; + } + pdf_add_stream(smask, (char *)smask_data_ptr, width*height); +diff -Naur a/texk/dvipsk/writet1.c b/texk/dvipsk/writet1.c +--- a/texk/dvipsk/writet1.c 2016-11-25 18:24:26.000000000 +0000 ++++ b/texk/dvipsk/writet1.c 2018-10-09 01:52:01.648670875 +0100 +@@ -1449,7 +1449,9 @@ + *(strend(t1_buf_array) - 1) = ' '; + + t1_getline(); ++ alloc_array(t1_buf, strlen(t1_line_array) + strlen(t1_buf_array) + 1, T1_BUF_SIZE); + strcat(t1_buf_array, t1_line_array); ++ alloc_array(t1_line, strlen(t1_buf_array) + 1, T1_BUF_SIZE); + strcpy(t1_line_array, t1_buf_array); + t1_line_ptr = eol(t1_line_array); + } +diff -Naur a/texk/web2c/luatexdir/font/writet1.w b/texk/web2c/luatexdir/font/writet1.w +--- a/texk/web2c/luatexdir/font/writet1.w 2016-11-25 18:24:34.000000000 +0000 ++++ b/texk/web2c/luatexdir/font/writet1.w 2018-10-09 01:52:01.648670875 +0100 +@@ -1625,7 +1625,9 @@ + if (sscanf(p, "%i", &i) != 1) { + strcpy(t1_buf_array, t1_line_array); + t1_getline(); ++ alloc_array(t1_buf, strlen(t1_line_array) + strlen(t1_buf_array) + 1, T1_BUF_SIZE); + strcat(t1_buf_array, t1_line_array); ++ alloc_array(t1_line, strlen(t1_buf_array) + 1, T1_BUF_SIZE); + strcpy(t1_line_array, t1_buf_array); + t1_line_ptr = eol(t1_line_array); + } +diff -Naur a/texk/web2c/luatexdir/image/pdftoepdf.w b/texk/web2c/luatexdir/image/pdftoepdf.w +--- a/texk/web2c/luatexdir/image/pdftoepdf.w 2018-01-17 18:00:12.000000000 +0000 ++++ b/texk/web2c/luatexdir/image/pdftoepdf.w 2018-10-09 01:52:01.648670875 +0100 +@@ -472,10 +472,10 @@ + break; + */ + case objString: +- copyString(pdf, obj->getString()); ++ copyString(pdf, (GooString *)obj->getString()); + break; + case objName: +- copyName(pdf, obj->getName()); ++ copyName(pdf, (char *)obj->getName()); + break; + case objNull: + pdf_add_null(pdf); +diff -Naur a/texk/web2c/luatexdir/lua/lepdflib.cc b/texk/web2c/luatexdir/lua/lepdflib.cc +--- a/texk/web2c/luatexdir/lua/lepdflib.cc 2018-02-14 14:44:38.000000000 +0000 ++++ b/texk/web2c/luatexdir/lua/lepdflib.cc 2018-10-09 01:52:01.649670868 +0100 +@@ -674,7 +674,7 @@ + uin = (udstruct *) luaL_checkudata(L, 1, M_##in); \ + if (uin->pd != NULL && uin->pd->pc != uin->pc) \ + pdfdoc_changed_error(L); \ +- gs = ((in *) uin->d)->function(); \ ++ gs = (GooString *)((in *) uin->d)->function(); \ + if (gs != NULL) \ + lua_pushlstring(L, gs->getCString(), gs->getLength()); \ + else \ +@@ -1813,7 +1813,7 @@ + if (uin->pd != NULL && uin->pd->pc != uin->pc) + pdfdoc_changed_error(L); + if (((Object *) uin->d)->isString()) { +- gs = ((Object *) uin->d)->getString(); ++ gs = (GooString *)((Object *) uin->d)->getString(); + lua_pushlstring(L, gs->getCString(), gs->getLength()); + } else + lua_pushnil(L); +diff -Naur a/texk/web2c/pdftexdir/writet1.c b/texk/web2c/pdftexdir/writet1.c +--- a/texk/web2c/pdftexdir/writet1.c 2016-11-25 18:24:37.000000000 +0000 ++++ b/texk/web2c/pdftexdir/writet1.c 2018-10-09 01:52:01.649670868 +0100 +@@ -1598,7 +1598,9 @@ + *(strend(t1_buf_array) - 1) = ' '; + + t1_getline(); ++ alloc_array(t1_buf, strlen(t1_line_array) + strlen(t1_buf_array) + 1, T1_BUF_SIZE); + strcat(t1_buf_array, t1_line_array); ++ alloc_array(t1_line, strlen(t1_buf_array) + 1, T1_BUF_SIZE); + strcpy(t1_line_array, t1_buf_array); + t1_line_ptr = eol(t1_line_array); + } +diff -Naur a/texk/web2c/ptexdir/ptex_version.h b/texk/web2c/ptexdir/ptex_version.h +--- a/texk/web2c/ptexdir/ptex_version.h 2018-01-21 03:48:06.000000000 +0000 ++++ b/texk/web2c/ptexdir/ptex_version.h 2018-10-09 01:52:01.649670868 +0100 +@@ -1 +1 @@ +-#define PTEX_VERSION "p3.8.0" ++#define PTEX_VERSION "p3.8.1" +diff -Naur a/texk/web2c/ptexdir/tests/free_ixsp.tex b/texk/web2c/ptexdir/tests/free_ixsp.tex +--- a/texk/web2c/ptexdir/tests/free_ixsp.tex 1970-01-01 01:00:00.000000000 +0100 ++++ b/texk/web2c/ptexdir/tests/free_ixsp.tex 2018-10-09 01:52:01.649670868 +0100 +@@ -0,0 +1,53 @@ ++%#!eptex -ini -etex ++\let\dump\relax ++\batchmode ++\input plain ++ ++\errorstopmode ++\catcode`@=11 ++\newcount\@tempcnta ++\newcount\@tempcntb ++\newcount\@tempcntc ++\mathchardef\LIM=256 ++ ++\def\MYCHAR#1{% ++ \@tempcntc=\numexpr7*#1+"101\relax ++ \@tempcnta=\@tempcntc\divide\@tempcnta 94 ++ \@tempcntb=\numexpr\@tempcntc-94*\@tempcnta+1\relax ++ \ifnum\@tempcntb<0\advance\@tempcntb94 \advance\@tempcnta-1\fi ++ \advance\@tempcnta18 % 18区以降 ++ \CNTA=\kuten\numexpr"100*\@tempcnta+\@tempcntb\relax ++} ++ ++\newcount\CNT\newcount\CNTA ++\CNT=0 ++\loop ++ \MYCHAR\CNT ++ \message{\the\CNT.} ++ \inhibitxspcode\CNTA=1\relax ++ \advance\CNT1\relax ++ \ifnum\CNT<\LIM ++\repeat ++ ++\newcount\CNTB ++ ++\loop ++ \MYCHAR\CNTB ++ \global\inhibitxspcode\CNTA=3 ++{% ++\CNT=0 ++\loop ++ \MYCHAR\CNT ++ \count@=\numexpr 1-\inhibitxspcode\CNTA\relax ++ \ifnum\count@=0\else\ifnum\CNTB=\CNT\else ++ \errmessage{<\the\CNTB, \the\CNT, \the\inhibitxspcode\CNTA>}\fi\fi ++ \advance\CNT1\relax ++ \ifnum\CNT<\LIM ++\repeat ++} ++ \MYCHAR\CNTB ++ \global\inhibitxspcode\CNTA=1\relax ++ \advance\CNTB1\relax ++ \ifnum\CNTB<\LIM ++\repeat ++\bye +diff -Naur a/texk/web2c/ptexdir/tests/free_pena.tex b/texk/web2c/ptexdir/tests/free_pena.tex +--- a/texk/web2c/ptexdir/tests/free_pena.tex 1970-01-01 01:00:00.000000000 +0100 ++++ b/texk/web2c/ptexdir/tests/free_pena.tex 2018-10-09 01:52:01.649670868 +0100 +@@ -0,0 +1,52 @@ ++%#!eptex -ini -etex ++\let\dump\relax ++\batchmode ++\input plain ++ ++\errorstopmode ++\catcode`@=11 ++\newcount\@tempcnta ++\newcount\@tempcntb ++\newcount\@tempcntc ++\mathchardef\LIM=256 ++ ++\def\MYCHAR#1{% ++ \@tempcntc=\numexpr7*#1+"101\relax ++ \@tempcnta=\@tempcntc\divide\@tempcnta 94 ++ \@tempcntb=\numexpr\@tempcntc-94*\@tempcnta+1\relax ++ \ifnum\@tempcntb<0\advance\@tempcntb94 \advance\@tempcnta-1\fi ++ \advance\@tempcnta18 % 18区以降 ++ \CNTA=\kuten\numexpr"100*\@tempcnta+\@tempcntb\relax ++} ++ ++\newcount\CNT\newcount\CNTA ++\CNT=0 ++\loop ++ \MYCHAR\CNT ++ \message{\the\CNT.} ++ \prebreakpenalty\CNTA=\numexpr\CNT+1\relax ++ \advance\CNT1\relax ++ \ifnum\CNT<\LIM ++\repeat ++ ++\newcount\CNTB ++ ++\loop ++ \MYCHAR\CNTB ++ \global\prebreakpenalty\CNTA=0 ++{% ++\CNT=0 ++\loop ++ \MYCHAR\CNT ++ \count@=\numexpr -\CNT-1+\prebreakpenalty\CNTA\relax ++ \ifnum\count@=0\else\ifnum\CNTB=\CNT\else\errmessage{<\the\CNTB, \the\CNT>}\fi\fi ++ \advance\CNT1\relax ++ \ifnum\CNT<\LIM ++\repeat ++} ++ \MYCHAR\CNTB ++ \global\prebreakpenalty\CNTA=\numexpr\CNTB+1\relax ++ \advance\CNTB1\relax ++ \ifnum\CNTB<\LIM ++\repeat ++\bye diff --git a/gnu/packages/patches/texlive-bin-pdftex-poppler-compat.patch b/gnu/packages/patches/texlive-bin-pdftex-poppler-compat.patch deleted file mode 100644 index eba4733f32..0000000000 --- a/gnu/packages/patches/texlive-bin-pdftex-poppler-compat.patch +++ /dev/null @@ -1,188 +0,0 @@ -Fix compatibility with Poppler 0.72. - -These files are taken from the upstream "poppler0.72.0.cc" variants and -diffed against the "newpoppler" files from the 20180414 distribution. - -See revision 49336: -https://tug.org/svn/texlive/trunk/Build/source/texk/web2c/pdftexdir/ - ---- a/texk/web2c/pdftexdir/pdftoepdf-newpoppler.cc 1970-01-01 01:00:00.000000000 +0100 -+++ b/texk/web2c/pdftexdir/pdftoepdf-newpoppler.cc 2018-12-09 21:14:58.479732695 +0100 -@@ -22,7 +22,7 @@ - https://git.archlinux.org/svntogit/packages.git/plain/texlive-bin/trunk - by Arch Linux. A little modifications are made to avoid a crash for - some kind of pdf images, such as figure_missing.pdf in gnuplot. --The poppler should be 0.59.0 or newer versions. -+The poppler should be 0.72.0 or newer versions. - POPPLER_VERSION should be defined. - */ - -@@ -120,7 +120,7 @@ - - static InObj *inObjList; - static UsedEncoding *encodingList; --static GBool isInit = gFalse; -+static bool isInit = false; - - // -------------------------------------------------------------------- - // Maintain list of open embedded PDF files -@@ -317,7 +317,7 @@ - pdf_puts("<<\n"); - assert(r->type == objFont); // FontDescriptor is in fd_tree - for (i = 0, l = obj->dictGetLength(); i < l; ++i) { -- key = obj->dictGetKey(i); -+ key = (char *)obj->dictGetKey(i); - if (strncmp("FontDescriptor", key, strlen("FontDescriptor")) == 0 - || strncmp("BaseFont", key, strlen("BaseFont")) == 0 - || strncmp("Encoding", key, strlen("Encoding")) == 0) -@@ -427,7 +427,7 @@ - charset = fontdesc.dictLookup("CharSet"); - if (!charset.isNull() && - charset.isString() && is_subsetable(fontmap)) -- epdf_mark_glyphs(fd, (char *)charset.getString()->getCString()); -+ epdf_mark_glyphs(fd, (char *)charset.getString()->c_str()); - else - embed_whole_font(fd); - addFontDesc(fontdescRef.getRef(), fd); -@@ -454,7 +454,7 @@ - for (i = 0, l = obj->dictGetLength(); i < l; ++i) { - fontRef = obj->dictGetValNF(i); - if (fontRef.isRef()) -- copyFont(obj->dictGetKey(i), &fontRef); -+ copyFont((char *)obj->dictGetKey(i), &fontRef); - else if (fontRef.isDict()) { // some programs generate pdf with embedded font object - copyName((char *)obj->dictGetKey(i)); - pdf_puts(" "); -@@ -566,7 +566,7 @@ - pdf_printf("%s", convertNumToPDF(obj->getNum())); - } else if (obj->isString()) { - s = (GooString *)obj->getString(); -- p = s->getCString(); -+ p = (char *)s->c_str(); - l = s->getLength(); - if (strlen(p) == (unsigned int) l) { - pdf_puts("("); -@@ -664,7 +664,7 @@ - ("PDF inclusion: CID fonts are not supported" - " (try to disable font replacement to fix this)"); - } -- if ((s = ((Gfx8BitFont *) r->font)->getCharName(i)) != 0) -+ if ((s = (char *)((Gfx8BitFont *) r->font)->getCharName(i)) != 0) - glyphNames[i] = s; - else - glyphNames[i] = notdef; -@@ -683,7 +683,7 @@ - } - - // get the pagebox according to the pagebox_spec --static PDFRectangle *get_pagebox(Page * page, int pagebox_spec) -+static const PDFRectangle *get_pagebox(Page * page, int pagebox_spec) - { - if (pagebox_spec == pdfboxspecmedia) - return page->getMediaBox(); -@@ -715,7 +715,7 @@ - { - PdfDocument *pdf_doc; - Page *page; -- PDFRectangle *pagebox; -+ const PDFRectangle *pagebox; - #ifdef POPPLER_VERSION - int pdf_major_version_found, pdf_minor_version_found; - #else -@@ -724,8 +724,8 @@ - // initialize - if (!isInit) { - globalParams = new GlobalParams(); -- globalParams->setErrQuiet(gFalse); -- isInit = gTrue; -+ globalParams->setErrQuiet(false); -+ isInit = true; - } - // open PDF file - pdf_doc = find_add_document(image_name); -@@ -849,7 +849,7 @@ - pageObj = xref->fetch(pageRef->num, pageRef->gen); - pageDict = pageObj.getDict(); - rotate = page->getRotate(); -- PDFRectangle *pagebox; -+ const PDFRectangle *pagebox; - // write the Page header - pdf_puts("/Type /XObject\n"); - pdf_puts("/Subtype /Form\n"); -@@ -977,7 +977,7 @@ - } - l = dic1.getLength(); - for (i = 0; i < l; i++) { -- groupDict.dictAdd(copyString(dic1.getKey(i)), -+ groupDict.dictAdd((const char *)copyString(dic1.getKey(i)), - dic1.getValNF(i)); - } - // end modification -@@ -1001,14 +1001,14 @@ - pdf_puts("/Resources <<\n"); - for (i = 0, l = obj1->dictGetLength(); i < l; ++i) { - obj2 = obj1->dictGetVal(i); -- key = obj1->dictGetKey(i); -+ key = (char *)obj1->dictGetKey(i); - if (strcmp("Font", key) == 0) - copyFontResources(&obj2); - else if (strcmp("ProcSet", key) == 0) - copyProcSet(&obj2); - else -- copyOtherResources(&obj2, key); -+ copyOtherResources(&obj2, (char *)key); - } - pdf_puts(">>\n"); - } - ---- a/texk/web2c/pdftexdir/pdftosrc-newpoppler.cc 1970-01-01 01:00:00.000000000 +0100 -+++ b/texk/web2c/pdftexdir/pdftosrc-newpoppler.cc 2018-12-09 21:14:58.479732695 +0100 -@@ -20,7 +20,7 @@ - /* - This is based on the patch texlive-poppler-0.59.patch <2017-09-19> at - https://git.archlinux.org/svntogit/packages.git/plain/texlive-bin/trunk --by Arch Linux. The poppler should be 0.59.0 or newer versions. -+by Arch Linux. The poppler should be 0.72.0 or newer versions. - POPPLER_VERSION should be defined. - */ - -@@ -109,7 +109,7 @@ - fprintf(stderr, "No SourceName found\n"); - exit(1); - } -- outname = (char *)srcName.getString()->getCString(); -+ outname = (char *)srcName.getString()->c_str(); - // We cannot free srcName, as objname shares its string. - // srcName.free(); - } else if (objnum > 0) { -@@ -118,7 +118,7 @@ - fprintf(stderr, "Not a Stream object\n"); - exit(1); - } -- sprintf(buf, "%s", fileName->getCString()); -+ sprintf(buf, "%s", fileName->c_str()); - if ((p = strrchr(buf, '.')) == 0) - p = strchr(buf, 0); - if (objgen == 0) -@@ -128,7 +128,7 @@ - outname = buf; - } else { // objnum < 0 means we are extracting the XRef table - extract_xref_table = true; -- sprintf(buf, "%s", fileName->getCString()); -+ sprintf(buf, "%s", fileName->c_str()); - if ((p = strrchr(buf, '.')) == 0) - p = strchr(buf, 0); - sprintf(p, ".xref"); -@@ -173,9 +173,9 @@ - - // parse the header: object numbers and offsets - objStr.streamReset(); -- str = new EmbedStream(objStr.getStream(), Object(objNull), gTrue, first); -+ str = new EmbedStream(objStr.getStream(), Object(objNull), true, first); - lexer = new Lexer(xref, str); -- parser = new Parser(xref, lexer, gFalse); -+ parser = new Parser(xref, lexer, false); - for (n = 0; n < nObjects; ++n) { - obj1 = parser->getObj(); - obj2 = parser->getObj(); - diff --git a/gnu/packages/patches/texlive-bin-xetex-poppler-compat.patch b/gnu/packages/patches/texlive-bin-xetex-poppler-compat.patch deleted file mode 100644 index cac716cc59..0000000000 --- a/gnu/packages/patches/texlive-bin-xetex-poppler-compat.patch +++ /dev/null @@ -1,31 +0,0 @@ -Fix compatibility with Poppler 0.72. - -Patch taken from upstream: -https://tug.org/svn/texlive/trunk/Build/source/texk/web2c/xetexdir/pdfimage.cpp?r1=44964&r2=48969&diff_format=u - ---- a/texk/web2c/xetexdir/pdfimage.cpp 2017/08/06 07:12:02 44964 -+++ b/texk/web2c/xetexdir/pdfimage.cpp 2018/10/22 04:01:42 48969 -@@ -82,19 +82,19 @@ - switch (pdf_box) { - default: - case pdfbox_crop: -- r = page->getCropBox(); -+ r = (PDFRectangle *)page->getCropBox(); - break; - case pdfbox_media: -- r = page->getMediaBox(); -+ r = (PDFRectangle *)page->getMediaBox(); - break; - case pdfbox_bleed: -- r = page->getBleedBox(); -+ r = (PDFRectangle *)page->getBleedBox(); - break; - case pdfbox_trim: -- r = page->getTrimBox(); -+ r = (PDFRectangle *)page->getTrimBox(); - break; - case pdfbox_art: -- r = page->getArtBox(); -+ r = (PDFRectangle *)page->getArtBox(); - break; - } diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm index 5b29937672..e90e64a6ad 100644 --- a/gnu/packages/tex.scm +++ b/gnu/packages/tex.scm @@ -102,21 +102,23 @@ (base32 "0khyi6h015r2zfqgg0a44a2j7vmr1cy42knw7jbss237yvakc07y")) (patches - (list - ;; This is required for compatibility with Poppler 0.64.0 and to fix a - ;; segmentation fault in dvipdfm-x from XeTeX, and also contains a fix - ;; for CVE-2018-17407. - (origin - (method url-fetch) - (uri (string-append "http://www.linuxfromscratch.org/patches/blfs/" - "svn/texlive-" version "-source-upstream_fixes-2.patch")) - (file-name "texlive-poppler-compat.patch") - (sha256 - (base32 - "04sxy1qv9y575mxwyg3y7rx7mh540pfjqx7yni7ncb5wjbq9pq1a"))) - (search-patch "texlive-bin-luatex-poppler-compat.patch") - (search-patch "texlive-bin-pdftex-poppler-compat.patch") - (search-patch "texlive-bin-xetex-poppler-compat.patch"))))) + (let ((arch-patch + (lambda (name revision hash) + (origin + (method url-fetch) + (uri (string-append "https://git.archlinux.org/svntogit/packages.git" + "/plain/trunk/" name "?h=packages/texlive-bin" + "&id=" revision)) + (file-name (string-append "texlive-bin-" name)) + (sha256 (base32 hash))))) + (arch-revision "e1975bce0b9d270d7c9773c5beb7e87d61ee8f57")) + (append (search-patches "texlive-bin-CVE-2018-17407.patch" + "texlive-bin-luatex-poppler-compat.patch") + (list + (arch-patch "pdftex-poppler0.72.patch" arch-revision + "0p46b6xxxg2s3hx67r0wpz16g3qygx65hpc581xs3jz5pvsiq3y7") + (arch-patch "xetex-poppler-fixes.patch" arch-revision + "1jj1p5zkjljb7id9pjv29cw0cf8mwrgrh4ackgzz9c200vaqpsvx"))))))) (build-system gnu-build-system) (inputs `(("texlive-extra-src" ,texlive-extra-src) @@ -195,9 +197,9 @@ #t)) (add-after 'unpack 'use-code-for-new-poppler (lambda _ - (copy-file "texk/web2c/pdftexdir/pdftoepdf-newpoppler.cc" + (copy-file "texk/web2c/pdftexdir/pdftoepdf-poppler0.72.0.cc" "texk/web2c/pdftexdir/pdftoepdf.cc") - (copy-file "texk/web2c/pdftexdir/pdftosrc-newpoppler.cc" + (copy-file "texk/web2c/pdftexdir/pdftosrc-poppler0.72.0.cc" "texk/web2c/pdftexdir/pdftosrc.cc") #t)) (add-after 'unpack 'disable-failing-test -- cgit v1.2.3 From 3eed550072d6f71eff20de269d313fc1dfe3e332 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Mon, 1 Apr 2019 00:03:36 +0200 Subject: gnu: Remove gtk+/fixed. The merge preceding this commit ignored the replacement part of commit bc91562939ee002e84c95d13c907482b6d1e9339. This commit removes the remaining bits, as the patch is already included in GTK3 since version 3.24.3. * gnu/packages/patches/gtk3-fix-deprecation-macro-use.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove it. * gnu/packages/gtk.scm (gtk+/fixed): Remove variable. --- gnu/local.mk | 1 - gnu/packages/gtk.scm | 12 ---------- .../patches/gtk3-fix-deprecation-macro-use.patch | 28 ---------------------- 3 files changed, 41 deletions(-) delete mode 100644 gnu/packages/patches/gtk3-fix-deprecation-macro-use.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index c6cacd7ada..1332efdcff 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -876,7 +876,6 @@ dist_patch_DATA = \ %D%/packages/patches/gtk2-respect-GUIX_GTK2_PATH.patch \ %D%/packages/patches/gtk2-respect-GUIX_GTK2_IM_MODULE_FILE.patch \ %D%/packages/patches/gtk2-theme-paths.patch \ - %D%/packages/patches/gtk3-fix-deprecation-macro-use.patch \ %D%/packages/patches/gtk3-respect-GUIX_GTK3_PATH.patch \ %D%/packages/patches/gtk3-respect-GUIX_GTK3_IM_MODULE_FILE.patch \ %D%/packages/patches/gtkglext-disable-disable-deprecated.patch \ diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index 7527abbbac..6e63ca6614 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -822,18 +822,6 @@ application suites.") (variable "GUIX_GTK3_PATH") (files '("lib/gtk-3.0"))))))) -;; Fixes a bug in Gtk that causes crashes in IceCat and Emacs. -;; See , , -;; and . -(define gtk+/fixed - (package - (inherit gtk+) - (source (origin - (inherit (package-source gtk+)) - (patches - (cons (search-patch "gtk3-fix-deprecation-macro-use.patch") - (origin-patches (package-source gtk+)))))))) - ;;; ;;; Guile bindings. ;;; diff --git a/gnu/packages/patches/gtk3-fix-deprecation-macro-use.patch b/gnu/packages/patches/gtk3-fix-deprecation-macro-use.patch deleted file mode 100644 index e933555ffb..0000000000 --- a/gnu/packages/patches/gtk3-fix-deprecation-macro-use.patch +++ /dev/null @@ -1,28 +0,0 @@ -Copied from . -Fixes upstream bugs -and . - -diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c -index 97ada6d73919fba3dfe192dd66929e90bc7677bb..764e39495f7edb0c3efe41cca25b8bee4778887d 100644 ---- a/gdk/x11/gdkwindow-x11.c -+++ b/gdk/x11/gdkwindow-x11.c -@@ -2985,6 +2985,7 @@ gdk_window_x11_set_background (GdkWindow *window, - double r, g, b, a; - cairo_surface_t *surface; - cairo_matrix_t matrix; -+ cairo_pattern_t *parent_relative_pattern; - - if (GDK_WINDOW_DESTROYED (window)) - return; -@@ -2997,8 +2998,10 @@ gdk_window_x11_set_background (GdkWindow *window, - } - - G_GNUC_BEGIN_IGNORE_DEPRECATIONS -- if (pattern == gdk_x11_get_parent_relative_pattern ()) -+ parent_relative_pattern = gdk_x11_get_parent_relative_pattern (); - G_GNUC_END_IGNORE_DEPRECATIONS -+ -+ if (pattern == parent_relative_pattern) - { - GdkWindow *parent; - -- cgit v1.2.3 From c531fad7a0b528be68c8bd1b5749a4d01c5bfdd1 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 4 Apr 2019 22:15:04 +0300 Subject: gnu: flac: Fix CVE-2017-6888. * gnu/packages/xiph.scm (flac)[replacement]: New field. (flac/fixed): New variable. * gnu/packages/patches/flac-CVE-2017-6888.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. --- gnu/local.mk | 1 + gnu/packages/patches/flac-CVE-2017-6888.patch | 29 +++++++++++++++++++++++++++ gnu/packages/xiph.scm | 11 +++++++++- 3 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/flac-CVE-2017-6888.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index 1332efdcff..ac7531af03 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -771,6 +771,7 @@ dist_patch_DATA = \ %D%/packages/patches/findutils-localstatedir.patch \ %D%/packages/patches/findutils-makedev.patch \ %D%/packages/patches/findutils-test-xargs.patch \ + %D%/packages/patches/flac-CVE-2017-6888.patch \ %D%/packages/patches/flann-cmake-3.11.patch \ %D%/packages/patches/flint-ldconfig.patch \ %D%/packages/patches/foomatic-filters-CVE-2015-8327.patch \ diff --git a/gnu/packages/patches/flac-CVE-2017-6888.patch b/gnu/packages/patches/flac-CVE-2017-6888.patch new file mode 100644 index 0000000000..d2583201b4 --- /dev/null +++ b/gnu/packages/patches/flac-CVE-2017-6888.patch @@ -0,0 +1,29 @@ +https://git.xiph.org/?p=flac.git;a=patch;h=4f47b63e9c971e6391590caf00a0f2a5ed612e67 + +From 4f47b63e9c971e6391590caf00a0f2a5ed612e67 Mon Sep 17 00:00:00 2001 +From: Erik de Castro Lopo +Date: Sat, 8 Apr 2017 18:34:49 +1000 +Subject: [PATCH] stream_decoder.c: Fix a memory leak + +Leak reported by Secunia Research. +--- + src/libFLAC/stream_decoder.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/src/libFLAC/stream_decoder.c b/src/libFLAC/stream_decoder.c +index 14d5fe7f..a5527511 100644 +--- a/src/libFLAC/stream_decoder.c ++++ b/src/libFLAC/stream_decoder.c +@@ -1753,6 +1753,9 @@ FLAC__bool read_metadata_vorbiscomment_(FLAC__StreamDecoder *decoder, FLAC__Stre + } + memset (obj->comments[i].entry, 0, obj->comments[i].length) ; + if (!FLAC__bitreader_read_byte_block_aligned_no_crc(decoder->private_->input, obj->comments[i].entry, obj->comments[i].length)) { ++ /* Current i-th entry is bad, so we delete it. */ ++ free (obj->comments[i].entry) ; ++ obj->comments[i].entry = NULL ; + obj->num_comments = i; + goto skip; + } +-- +2.11.0 + diff --git a/gnu/packages/xiph.scm b/gnu/packages/xiph.scm index 43b0d2723a..49d23bf6d5 100644 --- a/gnu/packages/xiph.scm +++ b/gnu/packages/xiph.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2014 Sree Harsha Totakura ;;; Copyright © 2014 Mark H Weaver ;;; Copyright © 2015 Paul van der Walt -;;; Copyright © 2015, 2016, 2017 Efraim Flashner +;;; Copyright © 2015, 2016, 2017, 2019 Efraim Flashner ;;; Copyright © 2017, 2018 Marius Bakke ;;; Copyright © 2018 Tobias Geerinckx-Rice ;;; Copyright © 2018 Leo Famulari @@ -235,6 +235,7 @@ It currently supports: (define flac (package (name "flac") + (replacement flac/fixed) (version "1.3.2") (source (origin (method url-fetch) @@ -256,6 +257,14 @@ meaning that audio is compressed in FLAC without any loss in quality.") "See COPYING in the distribution.")) ; and LGPL and GPL (home-page "https://xiph.org/flac/"))) +(define flac/fixed + (package + (inherit flac) + (source + (origin + (inherit (package-source flac)) + (patches (search-patches "flac-CVE-2017-6888.patch")))))) + (define libkate (package (name "libkate") -- cgit v1.2.3 From b979028527add840175336b8f7b165caf60ec793 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 1 Apr 2019 22:39:45 -0400 Subject: gnu: Add python-robotframework. * gnu/packages/python-xyz.scm (python-robotframework): New variable. * gnu/packages/patches/python-robotframework-honor-source-date-epoch.patch: Add patch. * gnu/local.mk (dist_patch_DATA): Register it. --- gnu/local.mk | 1 + ...on-robotframework-honor-source-date-epoch.patch | 62 ++++++++++++++++++++++ gnu/packages/python-xyz.scm | 45 ++++++++++++++++ 3 files changed, 108 insertions(+) create mode 100644 gnu/packages/patches/python-robotframework-honor-source-date-epoch.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index a3cfee9649..5c03066853 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1206,6 +1206,7 @@ dist_patch_DATA = \ %D%/packages/patches/python-pycrypto-CVE-2013-7459.patch \ %D%/packages/patches/python2-pygobject-2-gi-info-type-error-domain.patch \ %D%/packages/patches/python-pygpgme-fix-pinentry-tests.patch \ + %D%/packages/patches/python-robotframework-honor-source-date-epoch.patch \ %D%/packages/patches/python2-subprocess32-disable-input-test.patch \ %D%/packages/patches/python-unittest2-python3-compat.patch \ %D%/packages/patches/python-unittest2-remove-argparse.patch \ diff --git a/gnu/packages/patches/python-robotframework-honor-source-date-epoch.patch b/gnu/packages/patches/python-robotframework-honor-source-date-epoch.patch new file mode 100644 index 0000000000..ccd87911d8 --- /dev/null +++ b/gnu/packages/patches/python-robotframework-honor-source-date-epoch.patch @@ -0,0 +1,62 @@ +From 3cc41c05fad5601c0dd1832f64a6e9efca017727 Mon Sep 17 00:00:00 2001 +From: Maxim Cournoyer +Date: Mon, 1 Apr 2019 11:36:04 -0400 +Subject: [PATCH] robottime: Honor the SOURCE_DATE_EPOCH environment variable. + +Honoring the SOURCE_DATE_EPOCH environment variable allows building +the documentation using libdoc reproducibly, by setting the generated +timestamp to a fixed value. + +For more background on reproducible builds and the SOURCE_DATE_EPOCH +environment variable, see: +https://reproducible-builds.org/specs/source-date-epoch/. + +* src/robot/utils/robottime.py: import `os'. +(TimestampCache._get_epoch): Retrieve date from SOURCE_DATE_EPOCH if +it is defined, otherwise from time.time(). +* utest/output/test_logger.py (TestLogger.test_write_to_one_logger): +Check for the existance of a timestamp attribute instead of checking +for its content as the later is easy to break when using the +SOURCE_DATE_EPOCH environment variable. +--- + src/robot/utils/robottime.py | 3 +++ + utest/output/test_logger.py | 2 +- + 2 files changed, 4 insertions(+), 1 deletion(-) + +diff --git a/src/robot/utils/robottime.py b/src/robot/utils/robottime.py +index 06432a4a6..91526f826 100644 +--- a/src/robot/utils/robottime.py ++++ b/src/robot/utils/robottime.py +@@ -14,6 +14,7 @@ + # limitations under the License. + + import datetime ++import os + import time + import re + +@@ -395,6 +396,8 @@ class TimestampCache(object): + + # Seam for mocking + def _get_epoch(self): ++ if os.getenv('SOURCE_DATE_EPOCH'): ++ return float(os.getenv('SOURCE_DATE_EPOCH')) + return time.time() + + def _use_cache(self, secs, *separators): +diff --git a/utest/output/test_logger.py b/utest/output/test_logger.py +index 92fe6d77d..e980227aa 100644 +--- a/utest/output/test_logger.py ++++ b/utest/output/test_logger.py +@@ -46,7 +46,7 @@ class TestLogger(unittest.TestCase): + logger = LoggerMock(('Hello, world!', 'INFO')) + self.logger.register_logger(logger) + self.logger.write('Hello, world!', 'INFO') +- assert_true(logger.msg.timestamp.startswith('20')) ++ assert_true(hasattr(logger.msg, 'timestamp')) + + def test_write_to_one_logger_with_trace_level(self): + logger = LoggerMock(('expected message', 'TRACE')) +-- +2.20.1 + diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index bebb7c5cb2..efc36662e0 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -2752,6 +2752,51 @@ designed to be used by Robot Framework and tools and libraries in its ecosystem, but can naturally be used also by other projects.") (license license:asl2.0))) +(define-public python-robotframework + (package + (name "python-robotframework") + (version "3.1.1") + ;; There are no tests in the PyPI archive. + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/robotframework/robotframework.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1aaiamc9l35m5sf7xl2qc5q9308v7sz3p1qgzcslsjxzddphyn4v")) + (patches (search-patches + "python-robotframework-honor-source-date-epoch.patch")))) + (build-system python-build-system) + (arguments + `(#:phases (modify-phases %standard-phases + (add-before 'build 'build-and-install-doc + (lambda* (#:key outputs #:allow-other-keys) + (let* ((doc-output (assoc-ref outputs "doc")) + (doc (string-append doc-output "/share/" + ,name "-" ,version "/"))) + (invoke "invoke" "library-docs" "all") + (mkdir-p doc) + (copy-recursively "doc/libraries" + (string-append doc "/libraries")) + #t))) + (replace 'check + (lambda _ + (invoke "python" "utest/run.py")))))) + (native-inputs + `(("python-invoke" ,python-invoke) + ("python-rellu" ,python-rellu) + ("python:tk" ,python "tk"))) ;used when building the HTML doc + (outputs '("out" "doc")) + (home-page "https://robotframework.org") + (synopsis "Generic automation framework") + (description "Robot Framework is a generic automation framework for +acceptance testing, acceptance test driven development (ATDD), and robotic +process automation (RPA).") + (license license:asl2.0))) + (define-public python-scp (package (name "python-scp") -- cgit v1.2.3