From b8b0f503eab9b10e909140fab05e0496e45800ad72007fbce86a2b6c49ec7fb1 Mon Sep 17 00:00:00 2001 From: Robert Schweikert Date: Wed, 24 Jan 2018 20:28:15 +0000 Subject: [PATCH] Accepting request 568727 from home:gmoro:branches:Cloud:Tools - patch distribution detection until a fix is delivered to python3 (bsc#997614) OBS-URL: https://build.opensuse.org/request/show/568727 OBS-URL: https://build.opensuse.org/package/show/Cloud:Tools/cloud-init?expand=0&rev=103 --- cloud-init-add-variant-cloudcfg.patch | 12 ++++++++++++ cloud-init.changes | 5 +++++ cloud-init.spec | 4 ++++ 3 files changed, 21 insertions(+) create mode 100644 cloud-init-add-variant-cloudcfg.patch diff --git a/cloud-init-add-variant-cloudcfg.patch b/cloud-init-add-variant-cloudcfg.patch new file mode 100644 index 0000000..c31681c --- /dev/null +++ b/cloud-init-add-variant-cloudcfg.patch @@ -0,0 +1,12 @@ +diff -up ./setup.py.cloudcfg ./setup.py +--- ./setup.py.cloudcfg 2018-01-16 19:05:51.172016283 +0000 ++++ ./setup.py 2018-01-16 19:06:24.380417971 +0000 +@@ -114,7 +114,7 @@ def render_tmpl(template): + atexit.register(shutil.rmtree, tmpd) + bname = os.path.basename(template).rstrip(tmpl_ext) + fpath = os.path.join(tmpd, bname) +- tiny_p([sys.executable, './tools/render-cloudcfg', template, fpath]) ++ tiny_p([sys.executable, './tools/render-cloudcfg', '--variant=suse', template, fpath]) + # return path relative to setup.py + return os.path.join(os.path.basename(tmpd), bname) + diff --git a/cloud-init.changes b/cloud-init.changes index 7a2eb4c..dd9e253 100644 --- a/cloud-init.changes +++ b/cloud-init.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jan 18 09:57:10 UTC 2018 - gmoro@suse.com + +- patch distribution detection until a fix is delivered to python3 (bsc#997614) + ------------------------------------------------------------------- Tue Jan 16 10:03:00 UTC 2018 - dimstar@opensuse.org diff --git a/cloud-init.spec b/cloud-init.spec index c109f36..bb09e2a 100644 --- a/cloud-init.spec +++ b/cloud-init.spec @@ -53,6 +53,7 @@ Patch35: cloud-init-final-no-apt.patch Patch36: cloud-init-resize-ro-btrfs.patch # FIXME cloud-init-reproduce-build.patch, expecting upstream merge Patch37: cloud-init-reproduce-build.patch +Patch38: cloud-init-add-variant-cloudcfg.patch BuildRequires: fdupes BuildRequires: filesystem # pkg-config is needed to find correct systemd unit dir @@ -218,6 +219,9 @@ Documentation and examples for cloud-init tools %patch35 -p1 %patch36 %patch37 +%if 0%{?suse_version} && 0%{?suse_version} >= 1500 +%patch38 +%endif %build %if 0%{?suse_version} && 0%{?suse_version} <= 1315