From patchwork Thu Nov 15 12:49:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 151224 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp6948790ljp; Thu, 15 Nov 2018 04:49:30 -0800 (PST) X-Google-Smtp-Source: AJdET5dNftdAgCCi4o7O61+tA7LKe8bvF0piyEJMmpoWYl4nBeaU6P/PmsS0VB3LbdDjK/KsQYYv X-Received: by 2002:a63:5518:: with SMTP id j24mr29426pgb.208.1542286169978; Thu, 15 Nov 2018 04:49:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542286169; cv=none; d=google.com; s=arc-20160816; b=EXKuftvweEiO8pGgwknSFbLr6qj8Y9xVzHTHauYm9AOAEPWwrmn794ZXL+xbouWd/3 oEIgXHEvqxDVDnY1c5hwaq5yBrT3zSquKljSb4ckXEC7PbxmOmwW+UN077WtDMJ9G5Nk NPKM9B6mTwE+TucfR1U1NlkF+oJ2P3zSKTjAk46+eXIwT2dD+8q9L6U0xVtRkURMOO0k iKa8KA3CnUWEgQVqDOXAK0UkLgDgVZpKPhlaplvnVhutcy9RwPQYPgG4zYo0QQWgLWkd KFHG9kGoRJNkGuSZOOZ1xk989/bDDZXThTcb63RW0/0kPFD84Ry+xurEj+vG5Wendd3c mJ/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:message-id:date:to:from:dkim-signature :delivered-to; bh=m4lzsdJmibRFPlvdHMka3alTP7w6TIUv73nHp90E6KE=; b=L7ZdyX+2fZhFWvYdVicyPuSZAc5CM73HFU+UQ47BmlcX053xmb6r/L2brfLag10Zbz L38HzUfGQj/A5twbi1zlLULCeYBSdhMSVJkot0lg7ZzGieCYincowhVPpL4NeJ0Cr4Sz trtPjJLGGYs7woPOr2+1CUnJNUtq7IWSvxGZrXL4i78gysd2i/Qa0SHLV/u1Ps7kMHiz PkZntW15nYAzi3ySS7RB1m26DWBb2+kCxYfRiKAG83opAOWpfOOyl4BNZS3lL/6fFMWb NyKN4av8AmbPniqt7cyIi8lCXQNdUNARJgsJ/2rAWZwnduGRBuuVZOhTysMJXeexRgVU cmoA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=EWJbe7tq; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id k64si26418157pge.7.2018.11.15.04.49.29; Thu, 15 Nov 2018 04:49:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=EWJbe7tq; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from 165.28.230.35.bc.googleusercontent.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 4FD4D6C1A3; Thu, 15 Nov 2018 12:49:27 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wr1-f54.google.com (mail-wr1-f54.google.com [209.85.221.54]) by mail.openembedded.org (Postfix) with ESMTP id 7B42C6C19F for ; Thu, 15 Nov 2018 12:49:25 +0000 (UTC) Received: by mail-wr1-f54.google.com with SMTP id u9-v6so21095222wrr.0 for ; Thu, 15 Nov 2018 04:49:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id; bh=o1c8XAFoyvJDsiM7GcHtqzOQ1W0KAnbj0glsavRp1fc=; b=EWJbe7tq2DLqqIp8pvoXz3IyYot1AM7Y3IK+zO7aLljXJKqtgD7q1P3LdjIsl+DxQQ 1gg7YqUJt5JvS9zvP89q3bu0L6VrpHen6l4VzmQjcVKaf0lUZt8HkfzXF8lAT20SvrWG H9AfsUuG/7bJvQVfGNfrchw0UXCIIAUbfHjKTGRNYZLW0xnIN/pKt+W+n9b6LV/bpAWN sHgZBLAufZvAI/C1uHPHlb+ZnxDrV03bOXrv9upe/m+vPFK5r+HPPSft1bPkjlR38P+5 yNi/hf/bplOwwZ/57WrC8klAXmtmZOHdlUV4XJgXbSQW8OB3NzfmiE2um02ok03WtIuJ aDGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=o1c8XAFoyvJDsiM7GcHtqzOQ1W0KAnbj0glsavRp1fc=; b=i1wOj2yM6eTHdJjeTF9s85PkmGh2N0Ukziu6OyCbQ6k2IVn+D6/veG3lNg1vc0JJtJ BnR2oKWpZz5vQ/AGUeVsB1i4MOi6vdtDxx5gAC4eVAqfQdOWIpZZJ4usfBZvIOQc8LJ8 1cs75DaX8JkPSzhVBpkKKagVijExS+XkJSPrCbcETrWRojRr1o654T8el4UhzVXf1yAr /1+TYQLoQTPXLVWr+/P2w3/AySy8ACZOkzB68ZOGGlKyLHgxbW6YLAukqTvCueZO9ygA Z0ObtrHXbAofaJHzaGnZhS/avlPd3SY4uuiCJs7Wo14mGVQ/5945hrKtVeD97hjR9+YT T9Bw== X-Gm-Message-State: AGRZ1gLrrhRokzV0gYPL6PhkxxZTZe8t71zkmrxcNBxRiRydoLGEhqS9 /Uqm24+58G4MinPgVfwbP+BMyc52RKw= X-Received: by 2002:a5d:4fcb:: with SMTP id h11mr5707967wrw.139.1542286165830; Thu, 15 Nov 2018 04:49:25 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id h16-v6sm24507590wrb.73.2018.11.15.04.49.24 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 15 Nov 2018 04:49:25 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Thu, 15 Nov 2018 12:49:23 +0000 Message-Id: <20181115124923.32661-1-ross.burton@intel.com> X-Mailer: git-send-email 2.11.0 Subject: [OE-core] [PATCH] dnf: backport a patch to fix execution under Python 3.7 X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Python 3.7 removed the os.errno import, so fix dnf to use the correct import. Signed-off-by: Ross Burton --- meta/recipes-devtools/dnf/dnf/errno.patch | 36 +++++++++++++++++++++++++++++++ meta/recipes-devtools/dnf/dnf_2.7.5.bb | 1 + 2 files changed, 37 insertions(+) create mode 100644 meta/recipes-devtools/dnf/dnf/errno.patch -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-devtools/dnf/dnf/errno.patch b/meta/recipes-devtools/dnf/dnf/errno.patch new file mode 100644 index 00000000000..76a1690b765 --- /dev/null +++ b/meta/recipes-devtools/dnf/dnf/errno.patch @@ -0,0 +1,36 @@ +Don't use os.errno as that should never have existed, and doesn't exist with +Python 3.7. + +Upstream-Status: Backport +Signed-off-by: Ross Burton + +From 199fc9cb11ff004fc752b58b7177aaf8d7fcedfd Mon Sep 17 00:00:00 2001 +From: Neal Gompa +Date: Sat, 3 Mar 2018 12:44:54 -0500 +Subject: [PATCH] util: Correctly source errno.EEXIST + +--- + dnf/util.py | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/dnf/util.py b/dnf/util.py +index ab7fd279c..d0f1a4f25 100644 +--- a/dnf/util.py ++++ b/dnf/util.py +@@ -28,6 +28,7 @@ + import dnf + import dnf.const + import dnf.pycomp ++import errno + import itertools + import librepo + import locale +@@ -120,7 +121,7 @@ def ensure_dir(dname): + try: + os.makedirs(dname, mode=0o755) + except OSError as e: +- if e.errno != os.errno.EEXIST or not os.path.isdir(dname): ++ if e.errno != errno.EEXIST or not os.path.isdir(dname): + raise e + + def empty(iterable): \ No newline at end of file diff --git a/meta/recipes-devtools/dnf/dnf_2.7.5.bb b/meta/recipes-devtools/dnf/dnf_2.7.5.bb index df60d731b69..e2754fbb932 100644 --- a/meta/recipes-devtools/dnf/dnf_2.7.5.bb +++ b/meta/recipes-devtools/dnf/dnf_2.7.5.bb @@ -10,6 +10,7 @@ SRC_URI = "git://github.com/rpm-software-management/dnf.git \ file://0005-Do-not-prepend-installroot-to-logdir.patch \ file://0029-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch \ file://0030-Run-python-scripts-using-env.patch \ + file://errno.patch \ " SRCREV = "564c44667c7014843fa6f1732621093114ec59b2"