From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 840F1158087 for ; Sat, 15 Jan 2022 14:15:14 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B56AE2BC03E; Sat, 15 Jan 2022 14:15:13 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 74E2E2BC03E for ; Sat, 15 Jan 2022 14:15:13 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 3E16B342C7C for ; Sat, 15 Jan 2022 14:15:12 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id A88FE29A for ; Sat, 15 Jan 2022 14:15:10 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1642256099.721a4664fee78f80d4c0a370b80479e22bf1f1bb.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: app-text/ghostscript-gpl/, app-text/ghostscript-gpl/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: app-text/ghostscript-gpl/Manifest app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-CVE-2021-3781.patch app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps-2.patch app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps.patch app-text/ghostscript-gpl/ghostscript-gpl-9.54.0-r1.ebuild X-VCS-Directories: app-text/ghostscript-gpl/ app-text/ghostscript-gpl/files/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: 721a4664fee78f80d4c0a370b80479e22bf1f1bb X-VCS-Branch: master Date: Sat, 15 Jan 2022 14:15:10 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 19141c37-06b4-4367-bd4f-46ba312226e8 X-Archives-Hash: 93e57d16deb7d42cb889f8a6319258fe commit: 721a4664fee78f80d4c0a370b80479e22bf1f1bb Author: Andreas Sturmlechner gentoo org> AuthorDate: Sat Jan 15 12:43:39 2022 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Sat Jan 15 14:14:59 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=721a4664 app-text/ghostscript-gpl: Drop 9.54.0-r1 Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Andreas Sturmlechner gentoo.org> app-text/ghostscript-gpl/Manifest | 2 - .../ghostscript-gpl-9.54.0-CVE-2021-3781.patch | 213 --------------------- .../ghostscript-gpl-9.54.0-makefile-deps-2.patch | 96 ---------- .../ghostscript-gpl-9.54.0-makefile-deps.patch | 112 ----------- .../ghostscript-gpl-9.54.0-r1.ebuild | 194 ------------------- 5 files changed, 617 deletions(-) diff --git a/app-text/ghostscript-gpl/Manifest b/app-text/ghostscript-gpl/Manifest index 7715946cfaaf..6458096e7f7b 100644 --- a/app-text/ghostscript-gpl/Manifest +++ b/app-text/ghostscript-gpl/Manifest @@ -1,4 +1,2 @@ -DIST ghostscript-9.54.0.tar.xz 56001768 BLAKE2B 4a98b1af74c4b4caf8d263cd5529059304a76884418c90401b0fc9a89e0f5de5417a439f6e08b95374e62158eec65528ef5f949497d5050a6408fb7c87e54aa9 SHA512 a3c96925f4dbf5e276fc543b88df185a0435c68166db15ac532094329ba8db314d739a292da18be7954daaafeeb290e641ea03edf888854d7e752998ec6062cc DIST ghostscript-9.55.0.tar.xz 67417724 BLAKE2B 87827856aa60c2c4a4ed209bc4203a837107df0404af036a48e5baa23fccfc945a97fe328a80b15c7357fc71acb82721d4b96e5f726d8c9d836fee031916aef7 SHA512 42c7e05ba72e9fdd626c5412187b13fc3c9459cae57dfe49ddd3011bf4e2cbd10bc88f09068a9f777c2ec6ae881cd737fd700ab62ec5108f2aca69152588f38e -DIST ghostscript-gpl-9.54-patchset-01.tar.xz 2600 BLAKE2B e89f16f149ba3c46b1e81d774a3dca8345dfb60ec959249292cc0f3d8bc811ac169e232e3fb85de9d0ce65dd41453f90461798007b8b9fdd2c6e44d55e7a9d10 SHA512 0c49fbe6ece86b0c7729421cf06a6a210341fbe676efd89c0f97c96a426d3156e6a8ee596e050b8ee6a1af7a94ea8d1d54a6166f020a7d40fec95949cd7f3b12 DIST ghostscript-gpl-9.55-patchset-01.tar.xz 2940 BLAKE2B 450498f0bd191d5936de1c2bdff659f075c39f7f7fefaf85b438f51967c4a8c294c6c887b36d5c0429d3677fb06e171e77da4b81ec911efea96df5b107d489dc SHA512 87411e68a078f77171128392962a9cd7a639bf6082447c658a50017cbf3f4e3ebce63af46eb9befdf2c1317de3a7a17e389f4de6e3aeae83d519b1c7b36de3c8 diff --git a/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-CVE-2021-3781.patch b/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-CVE-2021-3781.patch deleted file mode 100644 index 779bedad4bde..000000000000 --- a/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-CVE-2021-3781.patch +++ /dev/null @@ -1,213 +0,0 @@ -https://git.ghostscript.com/?p=ghostpdl.git;a=commit;h=a9bd3dec9fde03327a4a2c69dad1036bf9632e20 -https://bugs.gentoo.org/812509 - -From: Chris Liddell -Date: Tue, 7 Sep 2021 20:36:12 +0100 -Subject: [PATCH 1/1] Bug 704342: Include device specifier strings in access - validation - -for the "%pipe%", %handle%" and %printer% io devices. - -We previously validated only the part after the "%pipe%" Postscript device -specifier, but this proved insufficient. - -This rebuilds the original file name string, and validates it complete. The -slight complication for "%pipe%" is it can be reached implicitly using -"|" so we have to check both prefixes. - -Addresses CVE-2021-3781 ---- a/base/gdevpipe.c -+++ b/base/gdevpipe.c -@@ -72,8 +72,28 @@ pipe_fopen(gx_io_device * iodev, const char *fname, const char *access, - #else - gs_lib_ctx_t *ctx = mem->gs_lib_ctx; - gs_fs_list_t *fs = ctx->core->fs; -+ /* The pipe device can be reached in two ways, explicltly with %pipe% -+ or implicitly with "|", so we have to check for both -+ */ -+ char f[gp_file_name_sizeof]; -+ const char *pipestr = "|"; -+ const size_t pipestrlen = strlen(pipestr); -+ const size_t preflen = strlen(iodev->dname); -+ const size_t nlen = strlen(fname); -+ int code1; -+ -+ if (preflen + nlen >= gp_file_name_sizeof) -+ return_error(gs_error_invalidaccess); -+ -+ memcpy(f, iodev->dname, preflen); -+ memcpy(f + preflen, fname, nlen + 1); -+ -+ code1 = gp_validate_path(mem, f, access); -+ -+ memcpy(f, pipestr, pipestrlen); -+ memcpy(f + pipestrlen, fname, nlen + 1); - -- if (gp_validate_path(mem, fname, access) != 0) -+ if (code1 != 0 && gp_validate_path(mem, f, access) != 0 ) - return gs_error_invalidfileaccess; - - /* ---- a/base/gp_mshdl.c -+++ b/base/gp_mshdl.c -@@ -95,8 +95,17 @@ mswin_handle_fopen(gx_io_device * iodev, const char *fname, const char *access, - long hfile; /* Correct for Win32, may be wrong for Win64 */ - gs_lib_ctx_t *ctx = mem->gs_lib_ctx; - gs_fs_list_t *fs = ctx->core->fs; -+ char f[gp_file_name_sizeof]; -+ const size_t preflen = strlen(iodev->dname); -+ const size_t nlen = strlen(fname); - -- if (gp_validate_path(mem, fname, access) != 0) -+ if (preflen + nlen >= gp_file_name_sizeof) -+ return_error(gs_error_invalidaccess); -+ -+ memcpy(f, iodev->dname, preflen); -+ memcpy(f + preflen, fname, nlen + 1); -+ -+ if (gp_validate_path(mem, f, access) != 0) - return gs_error_invalidfileaccess; - - /* First we try the open_handle method. */ ---- a/base/gp_msprn.c -+++ b/base/gp_msprn.c -@@ -168,8 +168,16 @@ mswin_printer_fopen(gx_io_device * iodev, const char *fname, const char *access, - uintptr_t *ptid = &((tid_t *)(iodev->state))->tid; - gs_lib_ctx_t *ctx = mem->gs_lib_ctx; - gs_fs_list_t *fs = ctx->core->fs; -+ const size_t preflen = strlen(iodev->dname); -+ const size_t nlen = strlen(fname); - -- if (gp_validate_path(mem, fname, access) != 0) -+ if (preflen + nlen >= gp_file_name_sizeof) -+ return_error(gs_error_invalidaccess); -+ -+ memcpy(pname, iodev->dname, preflen); -+ memcpy(pname + preflen, fname, nlen + 1); -+ -+ if (gp_validate_path(mem, pname, access) != 0) - return gs_error_invalidfileaccess; - - /* First we try the open_printer method. */ ---- a/base/gp_os2pr.c -+++ b/base/gp_os2pr.c -@@ -107,9 +107,20 @@ os2_printer_fopen(gx_io_device * iodev, const char *fname, const char *access, - FILE ** pfile, char *rfname, uint rnamelen) - { - os2_printer_t *pr = (os2_printer_t *)iodev->state; -- char driver_name[256]; -+ char driver_name[gp_file_name_sizeof]; - gs_lib_ctx_t *ctx = mem->gs_lib_ctx; - gs_fs_list_t *fs = ctx->core->fs; -+ const size_t preflen = strlen(iodev->dname); -+ const int size_t = strlen(fname); -+ -+ if (preflen + nlen >= gp_file_name_sizeof) -+ return_error(gs_error_invalidaccess); -+ -+ memcpy(driver_name, iodev->dname, preflen); -+ memcpy(driver_name + preflen, fname, nlen + 1); -+ -+ if (gp_validate_path(mem, driver_name, access) != 0) -+ return gs_error_invalidfileaccess; - - /* First we try the open_printer method. */ - /* Note that the loop condition here ensures we don't ---- a/base/gslibctx.c -+++ b/base/gslibctx.c -@@ -655,82 +655,39 @@ rewrite_percent_specifiers(char *s) - int - gs_add_outputfile_control_path(gs_memory_t *mem, const char *fname) - { -- char *fp, f[gp_file_name_sizeof]; -- const int pipe = 124; /* ASCII code for '|' */ -- const int len = strlen(fname); -- int i, code; -+ char f[gp_file_name_sizeof]; -+ int code; - - /* Be sure the string copy will fit */ -- if (len >= gp_file_name_sizeof) -+ if (strlen(fname) >= gp_file_name_sizeof) - return gs_error_rangecheck; - strcpy(f, fname); -- fp = f; - /* Try to rewrite any %d (or similar) in the string */ - rewrite_percent_specifiers(f); -- for (i = 0; i < len; i++) { -- if (f[i] == pipe) { -- fp = &f[i + 1]; -- /* Because we potentially have to check file permissions at two levels -- for the output file (gx_device_open_output_file and the low level -- fopen API, if we're using a pipe, we have to add both the full string, -- (including the '|', and just the command to which we pipe - since at -- the pipe_fopen(), the leading '|' has been stripped. -- */ -- code = gs_add_control_path(mem, gs_permit_file_writing, f); -- if (code < 0) -- return code; -- code = gs_add_control_path(mem, gs_permit_file_control, f); -- if (code < 0) -- return code; -- break; -- } -- if (!IS_WHITESPACE(f[i])) -- break; -- } -- code = gs_add_control_path(mem, gs_permit_file_control, fp); -+ -+ code = gs_add_control_path(mem, gs_permit_file_control, f); - if (code < 0) - return code; -- return gs_add_control_path(mem, gs_permit_file_writing, fp); -+ return gs_add_control_path(mem, gs_permit_file_writing, f); - } - - int - gs_remove_outputfile_control_path(gs_memory_t *mem, const char *fname) - { -- char *fp, f[gp_file_name_sizeof]; -- const int pipe = 124; /* ASCII code for '|' */ -- const int len = strlen(fname); -- int i, code; -+ char f[gp_file_name_sizeof]; -+ int code; - - /* Be sure the string copy will fit */ -- if (len >= gp_file_name_sizeof) -+ if (strlen(fname) >= gp_file_name_sizeof) - return gs_error_rangecheck; - strcpy(f, fname); -- fp = f; - /* Try to rewrite any %d (or similar) in the string */ -- for (i = 0; i < len; i++) { -- if (f[i] == pipe) { -- fp = &f[i + 1]; -- /* Because we potentially have to check file permissions at two levels -- for the output file (gx_device_open_output_file and the low level -- fopen API, if we're using a pipe, we have to add both the full string, -- (including the '|', and just the command to which we pipe - since at -- the pipe_fopen(), the leading '|' has been stripped. -- */ -- code = gs_remove_control_path(mem, gs_permit_file_writing, f); -- if (code < 0) -- return code; -- code = gs_remove_control_path(mem, gs_permit_file_control, f); -- if (code < 0) -- return code; -- break; -- } -- if (!IS_WHITESPACE(f[i])) -- break; -- } -- code = gs_remove_control_path(mem, gs_permit_file_control, fp); -+ rewrite_percent_specifiers(f); -+ -+ code = gs_remove_control_path(mem, gs_permit_file_control, f); - if (code < 0) - return code; -- return gs_remove_control_path(mem, gs_permit_file_writing, fp); -+ return gs_remove_control_path(mem, gs_permit_file_writing, f); - } - - int diff --git a/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps-2.patch b/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps-2.patch deleted file mode 100644 index 38f0eaa1516f..000000000000 --- a/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps-2.patch +++ /dev/null @@ -1,96 +0,0 @@ -From: Sam James -Date: Tue, 28 Sep 2021 03:40:19 +0100 -Subject: [PATCH] Rebased versions of upstream Makefile patches - -https://git.ghostscript.com/?p=ghostpdl.git;a=commit;h=cf868c13c03a781243c1d8764cbeba3a49ffb92e -https://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=c8285e6e9cd42277ae298475ad0c96da009b0e98 -https://bugs.gentoo.org/800125 ---- a/devices/devs.mak -+++ b/devices/devs.mak -@@ -669,7 +669,7 @@ $(DD)txtwrite.dev : $(ECHOGS_XE) $(txtwrite_) $(GDEV)\ - $(DEVOBJ)gdevtxtw.$(OBJ) : $(DEVVECSRC)gdevtxtw.c $(GDEV) $(gdevkrnlsclass_h) \ - $(memory__h) $(string__h) $(gp_h) $(gsparam_h) $(gsutil_h) \ - $(gsdevice_h) $(gxfont_h) $(gxfont0_h) $(gstext_h) $(gxfcid_h)\ -- $(gxgstate_h) $(gxpath_h) $(gdevagl_h) $(DEVS_MAK) $(MAKEDIRS) $(DEVVECSRC)doc_common.h -+ $(gxgstate_h) $(gxpath_h) $(gdevagl_h) $(DEVS_MAK) $(DEVVECSRC)doc_common.h $(MAKEDIRS) - $(DEVCC) $(DEVO_)gdevtxtw.$(OBJ) $(C_) $(DEVVECSRC)gdevtxtw.c - - $(DEVOBJ)gdevagl.$(OBJ) : $(DEVVECSRC)gdevagl.c $(GDEV)\ -@@ -684,14 +684,14 @@ gdevagl_h=$(DEVVECSRC)gdevagl.h - docxwrite_=$(DEVOBJ)gdevdocxw.$(OBJ) $(DEVOBJ)gdevagl.$(OBJ) $(DEVOBJ)doc_common.$(OBJ) - - $(DD)docxwrite.dev : $(ECHOGS_XE) $(docxwrite_) $(GDEV)\ -- $(gdevagl_h) $(DEVS_MAK) $(MAKEDIRS) $(EXTRACT_OBJS) -+ $(gdevagl_h) $(DEVS_MAK) $(EXTRACT_OBJS) $(MAKEDIRS) - $(SETDEV2) $(DD)docxwrite $(docxwrite_) $(EXTRACT_OBJS) - - $(DEVOBJ)gdevdocxw.$(OBJ) : $(DEVVECSRC)gdevdocxw.c $(GDEV) $(gdevkrnlsclass_h) \ - $(memory__h) $(string__h) $(gp_h) $(gsparam_h) $(gsutil_h) \ - $(gsdevice_h) $(gxfont_h) $(gxfont0_h) $(gstext_h) $(gxfcid_h)\ -- $(gxgstate_h) $(gxpath_h) $(gdevagl_h) $(DEVS_MAK) $(MAKEDIRS) \ -- $(DEVVECSRC)doc_common.h -+ $(gxgstate_h) $(gxpath_h) $(gdevagl_h) $(DEVS_MAK) $(DEVVECSRC)doc_common.h \ -+ $(MAKEDIRS) - $(DEVCC) $(DEVO_)gdevdocxw.$(OBJ) $(C_) $(DEVVECSRC)gdevdocxw.c - - # Shared code used by txtwrite and docxwrite. -@@ -699,7 +699,7 @@ $(DEVOBJ)gdevdocxw.$(OBJ) : $(DEVVECSRC)gdevdocxw.c $(GDEV) $(gdevkrnlsclass_h) - $(DEVOBJ)doc_common.$(OBJ) : $(DEVVECSRC)doc_common.c $(GDEV) $(gdevkrnlsclass_h) \ - $(memory__h) $(string__h) $(gp_h) $(gsparam_h) $(gsutil_h) \ - $(gsdevice_h) $(gxfont_h) $(gxfont0_h) $(gstext_h) $(gxfcid_h)\ -- $(gxgstate_h) $(gxpath_h) $(gdevagl_h) $(DEVS_MAK) $(MAKEDIRS) $(DEVVECSRC)doc_common.h -+ $(gxgstate_h) $(gxpath_h) $(gdevagl_h) $(DEVS_MAK) $(DEVVECSRC)doc_common.h $(MAKEDIRS) - $(DEVCC) $(DEVO_)doc_common.$(OBJ) $(C_) $(DEVVECSRC)doc_common.c - - ---- a/devices/extract.mak -+++ b/devices/extract.mak -@@ -1,37 +1,37 @@ - extract_cc = $(CC) $(CCFLAGS) $(I_)$(EXTRACT_DIR)/include$(_I) $(I_)$(ZSRCDIR)$(_I) $(O_) - extract_out_prefix = $(GLOBJDIR)$(D)extract_ - --$(extract_out_prefix)alloc.$(OBJ): $(EXTRACT_DIR)/src/alloc.c -+$(extract_out_prefix)alloc.$(OBJ): $(EXTRACT_DIR)/src/alloc.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/alloc.c - --$(extract_out_prefix)astring.$(OBJ): $(EXTRACT_DIR)/src/astring.c -+$(extract_out_prefix)astring.$(OBJ): $(EXTRACT_DIR)/src/astring.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/astring.c - --$(extract_out_prefix)buffer.$(OBJ): $(EXTRACT_DIR)/src/buffer.c -+$(extract_out_prefix)buffer.$(OBJ): $(EXTRACT_DIR)/src/buffer.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/buffer.c - --$(extract_out_prefix)docx.$(OBJ): $(EXTRACT_DIR)/src/docx.c -+$(extract_out_prefix)docx.$(OBJ): $(EXTRACT_DIR)/src/docx.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/docx.c - --$(extract_out_prefix)docx_template.$(OBJ): $(EXTRACT_DIR)/src/docx_template.c -+$(extract_out_prefix)docx_template.$(OBJ): $(EXTRACT_DIR)/src/docx_template.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/docx_template.c - --$(extract_out_prefix)extract.$(OBJ): $(EXTRACT_DIR)/src/extract.c -+$(extract_out_prefix)extract.$(OBJ): $(EXTRACT_DIR)/src/extract.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/extract.c - --$(extract_out_prefix)join.$(OBJ): $(EXTRACT_DIR)/src/join.c -+$(extract_out_prefix)join.$(OBJ): $(EXTRACT_DIR)/src/join.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/join.c - --$(extract_out_prefix)mem.$(OBJ): $(EXTRACT_DIR)/src/mem.c -+$(extract_out_prefix)mem.$(OBJ): $(EXTRACT_DIR)/src/mem.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/mem.c - --$(extract_out_prefix)outf.$(OBJ): $(EXTRACT_DIR)/src/outf.c -+$(extract_out_prefix)outf.$(OBJ): $(EXTRACT_DIR)/src/outf.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/outf.c - --$(extract_out_prefix)xml.$(OBJ): $(EXTRACT_DIR)/src/xml.c -+$(extract_out_prefix)xml.$(OBJ): $(EXTRACT_DIR)/src/xml.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/xml.c - --$(extract_out_prefix)zip.$(OBJ): $(EXTRACT_DIR)/src/zip.c -+$(extract_out_prefix)zip.$(OBJ): $(EXTRACT_DIR)/src/zip.c $(MAKEDIRS) - $(extract_cc)$@ $(C_) $(EXTRACT_DIR)/src/zip.c - - EXTRACT_OBJS = \ diff --git a/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps.patch b/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps.patch deleted file mode 100644 index 51ce95958ba1..000000000000 --- a/app-text/ghostscript-gpl/files/ghostscript-gpl-9.54.0-makefile-deps.patch +++ /dev/null @@ -1,112 +0,0 @@ -https://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=4874418fd031617212336b8b55f8fcba3b9cfb68#patch1 -https://git.ghostscript.com/?p=ghostpdl.git;a=commit;h=cf868c13c03a781243c1d8764cbeba3a49ffb92e -https://git.ghostscript.com/?p=ghostpdl.git;a=patch;h=c8285e6e9cd42277ae298475ad0c96da009b0e98 -https://bugs.gentoo.org/800125 - -From: Chris Liddell -Date: Thu, 6 May 2021 12:23:59 +0100 -Subject: [PATCH] Remove makefile reference to non-existent header file - -Fixes (spurious) parallel make failure on the cluster ---- a/base/lib.mak -+++ b/base/lib.mak -@@ -488,7 +488,6 @@ gxcoord_h=$(GLSRC)gxcoord.h - gxcpath_h=$(GLSRC)gxcpath.h - gxdda_h=$(GLSRC)gxdda.h - gxdevbuf_h=$(GLSRC)gxdevbuf.h --gxdevrop_h=$(GLSRC)gxdevrop.h - gxdevmem_h=$(GLSRC)gxdevmem.h - gxdhtres_h=$(GLSRC)gxdhtres.h - gxfont0_h=$(GLSRC)gxfont0.h -@@ -2407,13 +2406,13 @@ $(GLD)roplib.dev : $(LIB_MAK) $(ECHOGS_XE) $(roplib_) $(LIB_MAK) $(MAKEDIRS) - - $(GLOBJ)gdevdrop_1.$(OBJ) : $(GLSRC)gdevdrop.c $(AK) $(gx_h) $(gserrors_h) \ - $(memory__h) $(gxdevsop_h) $(gsbittab_h) $(gsropt_h) $(gxcindex_h) \ -- $(gxdcolor_h) $(gxdevice_h) $(gxdevmem_h) $(gxdevrop_h) $(gxgetbit_h) \ -+ $(gxdcolor_h) $(gxdevice_h) $(gxdevmem_h) $(gxgetbit_h) \ - $(gdevmem_h) $(gdevmrop_h) $(gdevmpla_h) $(stdint__h) $(LIB_MAK) $(MAKEDIRS) - $(GLCC) $(D_)WITH_CAL$(_D) $(I_)$(CALSRCDIR)$(_I) $(GLO_)gdevdrop_1.$(OBJ) $(C_) $(GLSRC)gdevdrop.c - - $(GLOBJ)gdevdrop_0.$(OBJ) : $(GLSRC)gdevdrop.c $(AK) $(gx_h) $(gserrors_h) \ - $(memory__h) $(gxdevsop_h) $(gsbittab_h) $(gsropt_h) $(gxcindex_h) \ -- $(gxdcolor_h) $(gxdevice_h) $(gxdevmem_h) $(gxdevrop_h) $(gxgetbit_h) \ -+ $(gxdcolor_h) $(gxdevice_h) $(gxdevmem_h) $(gxgetbit_h) \ - $(gdevmem_h) $(gdevmrop_h) $(gdevmpla_h) $(stdint__h) $(LIB_MAK) $(MAKEDIRS) - $(GLCC) $(GLO_)gdevdrop_0.$(OBJ) $(C_) $(GLSRC)gdevdrop.c - -@@ -5585,75 +5584,6 @@ $(GLSRC)gxdevbuf.h:$(GLSRC)std.h - $(GLSRC)gxdevbuf.h:$(GLSRC)stdpre.h - $(GLSRC)gxdevbuf.h:$(GLGEN)arch.h - $(GLSRC)gxdevbuf.h:$(GLSRC)gs_dll_call.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxdevcli.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxcmap.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxtext.h --$(GLSRC)gxdevrop.h:$(GLSRC)gstext.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsnamecl.h --$(GLSRC)gxdevrop.h:$(GLSRC)gstparam.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxfmap.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsfunc.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxcspace.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxrplane.h --$(GLSRC)gxdevrop.h:$(GLSRC)gscsel.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxfcache.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsfont.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsimage.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsdcolor.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxcvalue.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxbcache.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsropt.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxdda.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxpath.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxfrac.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxtmap.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxftype.h --$(GLSRC)gxdevrop.h:$(GLSRC)gscms.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsrect.h --$(GLSRC)gxdevrop.h:$(GLSRC)gslparam.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsdevice.h --$(GLSRC)gxdevrop.h:$(GLSRC)gscpm.h --$(GLSRC)gxdevrop.h:$(GLSRC)gscspace.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsgstate.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsxfont.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsdsrc.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsiparam.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxfixed.h --$(GLSRC)gxdevrop.h:$(GLSRC)gscompt.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsmatrix.h --$(GLSRC)gxdevrop.h:$(GLSRC)gspenum.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxhttile.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsparam.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsrefct.h --$(GLSRC)gxdevrop.h:$(GLSRC)gp.h --$(GLSRC)gxdevrop.h:$(GLSRC)memento.h --$(GLSRC)gxdevrop.h:$(GLSRC)memory_.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsuid.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsstruct.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxsync.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxbitmap.h --$(GLSRC)gxdevrop.h:$(GLSRC)srdline.h --$(GLSRC)gxdevrop.h:$(GLSRC)scommon.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsbitmap.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsccolor.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxarith.h --$(GLSRC)gxdevrop.h:$(GLSRC)stat_.h --$(GLSRC)gxdevrop.h:$(GLSRC)gpsync.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsstype.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsmemory.h --$(GLSRC)gxdevrop.h:$(GLSRC)gpgetenv.h --$(GLSRC)gxdevrop.h:$(GLSRC)gscdefs.h --$(GLSRC)gxdevrop.h:$(GLSRC)gslibctx.h --$(GLSRC)gxdevrop.h:$(GLSRC)gxcindex.h --$(GLSRC)gxdevrop.h:$(GLSRC)stdio_.h --$(GLSRC)gxdevrop.h:$(GLSRC)gsccode.h --$(GLSRC)gxdevrop.h:$(GLSRC)stdint_.h --$(GLSRC)gxdevrop.h:$(GLSRC)gssprintf.h --$(GLSRC)gxdevrop.h:$(GLSRC)gstypes.h --$(GLSRC)gxdevrop.h:$(GLSRC)std.h --$(GLSRC)gxdevrop.h:$(GLSRC)stdpre.h --$(GLSRC)gxdevrop.h:$(GLGEN)arch.h --$(GLSRC)gxdevrop.h:$(GLSRC)gs_dll_call.h - $(GLSRC)gxdevmem.h:$(GLSRC)gxdevcli.h - $(GLSRC)gxdevmem.h:$(GLSRC)gxcmap.h - $(GLSRC)gxdevmem.h:$(GLSRC)gxtext.h diff --git a/app-text/ghostscript-gpl/ghostscript-gpl-9.54.0-r1.ebuild b/app-text/ghostscript-gpl/ghostscript-gpl-9.54.0-r1.ebuild deleted file mode 100644 index d112d0051958..000000000000 --- a/app-text/ghostscript-gpl/ghostscript-gpl-9.54.0-r1.ebuild +++ /dev/null @@ -1,194 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit autotools toolchain-funcs - -DESCRIPTION="Interpreter for the PostScript language and PDF" -HOMEPAGE="https://ghostscript.com/" - -MY_PN=${PN/-gpl} -MY_P="${MY_PN}-${PV/_}" -PVM=$(ver_cut 1-2) -PVM_S=$(ver_rs 1-2 "") - -MY_PATCHSET="ghostscript-gpl-9.54-patchset-01.tar.xz" - -SRC_URI="https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs${PVM_S}/${MY_P}.tar.xz" - -if [[ -n "${MY_PATCHSET}" ]] ; then - SRC_URI+=" https://dev.gentoo.org/~whissi/dist/ghostscript-gpl/${MY_PATCHSET}" -fi - -LICENSE="AGPL-3 CPL-1.0" -SLOT="0/$(ver_cut 1-2)" -KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="cups dbus gtk +jpeg2k l10n_de static-libs unicode X" - -LANGS="ja ko zh-CN zh-TW" -for X in ${LANGS} ; do - IUSE="${IUSE} l10n_${X}" -done - -DEPEND=" - app-text/libpaper - media-libs/fontconfig - >=media-libs/freetype-2.4.9:2= - >=media-libs/jbig2dec-0.19:= - >=media-libs/lcms-2.6:2 - >=media-libs/libpng-1.6.2:0= - >=media-libs/tiff-4.0.1:0= - >=sys-libs/zlib-1.2.7 - virtual/jpeg:0 - cups? ( >=net-print/cups-1.3.8 ) - dbus? ( sys-apps/dbus ) - gtk? ( || ( x11-libs/gtk+:3 x11-libs/gtk+:2 ) ) - jpeg2k? ( >=media-libs/openjpeg-2.1.0:2= ) - unicode? ( net-dns/libidn:0= ) - X? ( x11-libs/libXt x11-libs/libXext ) -" -BDEPEND="virtual/pkgconfig" -RDEPEND="${DEPEND} - app-text/poppler-data - >=media-fonts/urw-fonts-2.4.9 - l10n_ja? ( media-fonts/kochi-substitute ) - l10n_ko? ( media-fonts/baekmuk-fonts ) - l10n_zh-CN? ( media-fonts/arphicfonts ) - l10n_zh-TW? ( media-fonts/arphicfonts ) -" - -S="${WORKDIR}/${MY_P}" - -src_prepare() { - if [[ -n "${MY_PATCHSET}" ]] ; then - # apply various patches, many borrowed from Fedora - # https://src.fedoraproject.org/rpms/ghostscript - # and Debian - # https://salsa.debian.org/printing-team/ghostscript/-/tree/debian/latest/debian/patches - eapply "${WORKDIR}/patches/"*.patch - fi - - # Upstream patches - eapply "${FILESDIR}"/${P}-CVE-2021-3781.patch - eapply "${FILESDIR}"/${P}-makefile-deps.patch - eapply "${FILESDIR}"/${P}-makefile-deps-2.patch - - default - - # remove internal copies of various libraries - rm -r cups/libs || die - rm -r freetype || die - rm -r jbig2dec || die - rm -r jpeg || die - rm -r lcms2mt || die - rm -r libpng || die - rm -r tiff || die - rm -r zlib || die - rm -r openjpeg || die - # remove internal CMaps (CMaps from poppler-data are used instead) - rm -r Resource/CMap || die - - if ! use gtk ; then - sed -e "s:\$(GSSOX)::" \ - -e "s:.*\$(GSSOX_XENAME)$::" \ - -i base/unix-dll.mak || die "sed failed" - fi - - # Force the include dirs to a neutral location. - sed -e "/^ZLIBDIR=/s:=.*:=${T}:" \ - -i configure.ac || die - # Some files depend on zlib.h directly. Redirect them. #573248 - # Also make sure to not define OPJ_STATIC to avoid linker errors due to - # hidden symbols (https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=203327#c1) - sed -e '/^zlib_h/s:=.*:=:' \ - -e 's|-DOPJ_STATIC ||' \ - -i base/lib.mak || die - - # search path fix - # put LDFLAGS after BINDIR, bug #383447 - sed -e "s:\$\(gsdatadir\)/lib:@datarootdir@/ghostscript/${PV}/$(get_libdir):" \ - -e "s:exdir=.*:exdir=@datarootdir@/doc/${PF}/examples:" \ - -e "s:docdir=.*:docdir=@datarootdir@/doc/${PF}/html:" \ - -e "s:GS_DOCDIR=.*:GS_DOCDIR=@datarootdir@/doc/${PF}/html:" \ - -e 's:-L$(BINDIR):& $(LDFLAGS):g' \ - -i Makefile.in base/*.mak || die "sed failed" - - # remove incorrect symlink, bug 590384 - rm ijs/ltmain.sh || die - eautoreconf - - cd ijs || die - eautoreconf -} - -src_configure() { - local FONTPATH - for path in \ - "${EPREFIX}"/usr/share/fonts/urw-fonts \ - "${EPREFIX}"/usr/share/fonts/Type1 \ - "${EPREFIX}"/usr/share/fonts \ - "${EPREFIX}"/usr/share/poppler/cMap/Adobe-CNS1 \ - "${EPREFIX}"/usr/share/poppler/cMap/Adobe-GB1 \ - "${EPREFIX}"/usr/share/poppler/cMap/Adobe-Japan1 \ - "${EPREFIX}"/usr/share/poppler/cMap/Adobe-Japan2 \ - "${EPREFIX}"/usr/share/poppler/cMap/Adobe-Korea1 - do - FONTPATH="$FONTPATH${FONTPATH:+:}${EPREFIX}$path" - done - - PKGCONFIG=$(type -P $(tc-getPKG_CONFIG)) \ - econf \ - --enable-dynamic \ - --enable-freetype \ - --enable-fontconfig \ - $(use_enable jpeg2k openjpeg) \ - --disable-compile-inits \ - --with-drivers=ALL \ - --with-fontpath="$FONTPATH" \ - --with-ijs \ - --with-jbig2dec \ - --with-libpaper \ - --with-system-libtiff \ - $(use_enable cups) \ - $(use_enable dbus) \ - $(use_enable gtk) \ - $(use_with cups pdftoraster) \ - $(use_with unicode libidn) \ - $(use_with X x) \ - DARWIN_LDFLAGS_SO_PREFIX="${EPREFIX}/usr/lib/" - - cd "${S}/ijs" || die - econf \ - --enable-shared \ - $(use_enable static-libs static) -} - -src_compile() { - emake so all - - cd ijs || die - emake -} - -src_install() { - emake DESTDIR="${D}" install-so install - - # move gsc to gs, bug #343447 - # gsc collides with gambit, bug #253064 - mv -f "${ED}"/usr/bin/{gsc,gs} || die - - cd "${S}/ijs" || die - emake DESTDIR="${D}" install - - # install the CMaps from poppler-data properly, bug #409361 - dosym ../../../poppler/cMaps "/usr/share/ghostscript/${PV}/Resource/CMap" - - if ! use static-libs; then - find "${ED}" -name '*.la' -delete || die - fi - - if ! use l10n_de; then - rm -r "${ED}"/usr/share/man/de || die - fi -}