From nobody Tue Apr 16 19:35:04 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1505822772717485.5474058179195; Tue, 19 Sep 2017 05:06:12 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id A3A3E4E4D4; Tue, 19 Sep 2017 12:06:11 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7922560475; Tue, 19 Sep 2017 12:06:11 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 3DC3C1855945; Tue, 19 Sep 2017 12:06:11 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v8JBv1ZI026100 for ; Tue, 19 Sep 2017 07:57:01 -0400 Received: by smtp.corp.redhat.com (Postfix) id 6F3F04C7; Tue, 19 Sep 2017 11:57:01 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.42.22.189]) by smtp.corp.redhat.com (Postfix) with ESMTP id 826405C8B2; Tue, 19 Sep 2017 11:56:58 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com A3A3E4E4D4 Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com From: "Daniel P. Berrange" To: libvir-list@redhat.com Date: Tue, 19 Sep 2017 12:56:55 +0100 Message-Id: <20170919115655.14130-1-berrange@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH python] Add travis build config X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Tue, 19 Sep 2017 12:06:12 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Enable builds on several python versions, and against several versions of libvirt. Ideally we would build all the way back to 0.9.11, since that is the min supported libvirt for python binding. It is not possible to build this old libvirt version on modern distros though, so using 1.2.0 as the oldest for now. Signed-off-by: Daniel P. Berrange Reviewed-by: Martin Kletzander --- .travis.yml | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ setup.py | 13 +++++++------ 2 files changed, 62 insertions(+), 6 deletions(-) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..203d91d --- /dev/null +++ b/.travis.yml @@ -0,0 +1,55 @@ +language: python +os: linux + +python: + - 2.6 + - 2.7 + - 3.2 + - 3.6 + +env: + - LIBVIRT=3D1.2.0 EXT=3Dgz + - LIBVIRT=3D2.0.0 EXT=3Dxz + - LIBVIRT=3D3.6.0 EXT=3Dxz + +install: + - sudo apt-get -qqy build-dep libvirt libxml2-dev + - sudo apt-get -qqy install curl + - pip install lxml nose + - curl -O -s https://libvirt.org/sources/libvirt-${LIBVIRT}.tar.${EXT} + - tar -xf libvirt-${LIBVIRT}.tar.${EXT} + - pushd libvirt-${LIBVIRT} + - | + ./configure --prefix=3D`pwd`/../libvirt-vroot \ + --without-libvirtd \ + --without-esx \ + --without-vbox \ + --without-libxl \ + --without-xen \ + --without-qemu \ + --without-lxc \ + --without-hyperv \ + --without-macvtap \ + --disable-werror + - make + - make install + - popd + +script: + - LD_LIBRARY_PATH=3D`pwd`/libvirt-vroot/lib PKG_CONFIG_PATH=3D`pwd`/libv= irt-vroot/lib/pkgconfig python setup.py build sdist test + +notifications: + irc: + # The channel name "irc.oftc.net#virt" is encrypted against libvirt/li= bvirt + # to prevent IRC notifications from github forks. This was created usi= ng: + # $ travis encrypt -r "libvirt/libvirt" "irc.oftc.net#virt" + channels: + - secure: "K4JrbRpz4CHtZ1vjthVwseT8K6INJgjtZethP4DN1jOpm1uC5esbe1Q1q= JOfB92JbMcdM6DNjrVg5eyTJj35aD9UoGpTUcPMsYrhlTPHZtfAuLv/at2eB2XRmETlhiXHgI6L= izX6gTiwGW5ZHYwGChzumWxu141d/L9harNh9R6z8XH9uJpkNdOAIsJcwS56XGZ74CKsrqF5dK6= ZYPIyP+i7gPO67gEWo0oD6TiJKR908fw03ZiXarIFmLRlk4MbHywLRF0byfD0gg2Ht/tDX73+59= QXjLKo/GvQecwoU8UuuFRJlyhUfvm1JYYydnS+O7fPJvI0FWlYFY7i76aeVqkARHRpHknFueT6k= ZADOmiyMLuvdr+gWVuyIdX33vVJtDm4T1OtNMG/wy9EUZUU1vEu+gHhaRkf/O0GkMj0Hac4I14B= Gyd/Wdhto6zWojFiMEG/HRHey6l15MBQu49QyW/YMyWi/LeBWXuCUgwQ/ij5EPgsn36OxCafV9z= Mz0oXZskwX6rJGQRZsdgdwYvt2hP3muLaJbwVyT0bGlOJDJieOa/LVKOXPcQm26aGfyMuLgm0//= E9v++6W1IDKh6+BNsfTKAwTxlAvJyz6Bns3XuUJUxUz2+uQVSS6S3EwEZUJ+yHDd2F4sX5OP1L7= TWIOWFbI4vQK90ZZ7/jgiYQbwo=3D" + on_success: change + on_failure: always + email: + # The list name 'libvirt-ci@redhat.com" is encrypted against libvirt/l= ibvirt + # to prevent IRC notifications from github forks. This was created usi= ng: + # $ travis encrypt -r "libvirt/libvirt" "libvirt-ci@redhat.com" + recipients: + - secure: "l6TTLcEcXdDEldHE2NgSIdt6a0k99ug3hp2W4IlnqJWJfIk/87nysJtLN= rA0va20pPApCa3iJfMq4PUmBGiIIimTN0/KgC7tONDraogXhCbgfZp9Ejy/57TXxygSp4oum2kD= w/c5uLnfrFV/xcn1fk6hvH6CD3bVcJPOQ/mc5FSKLqN5UzwqNnMpMTtG9qxCwfXJ/Bdm9fbURfe= zC7djcYRwRfPUe3TSD0L76G2HnQnSy4RqR3KFSjQHFPnSGM5IbsokbOaFKCyp/pHOt7QomQaY7Y= APX/K9O+eP+hkkp6DGADkkumHctcgnMoyxpahf7pNKw9S8JYabH2NwREIq8whbp9Mo+R4rYO2oz= roLWHaboYs/pBLrs606ivTwOmWGRCpJdCmmKTiZNyo6MRrwiOM6x+2YHUTMOa2kVheRNzaaxMFz= HPW2kZ20bujPhfViJsRYj9flo5GJXJLyjluGZK5RjrguNJeIh8VJNBiSHW37uj7drmNBsqMad+6= 5mf/4xtGITBqhz5Spx5R9UMZbuiJvcm8GasJMMdQ+bCfuWYjF2nZvSvFEr54Ii1YrDp6FKQ8YG1= aD1/D8Z0/b3pLd/8Pn+M9yIWyO/Sto5TbSUjxBTmTStuDmtYE5uu1miYebvgJH5MovWPBegYgrf= I417kPJgCG3q/R0YcZFMKFfQyo=3D" diff --git a/setup.py b/setup.py index f33ff1a..cc3a09a 100755 --- a/setup.py +++ b/setup.py @@ -290,15 +290,16 @@ class my_test(Command): 'lib' + plat_specifier) =20 def find_nosetests_path(self): - paths =3D [ - "/usr/bin/nosetests-%d.%d" % (sys.version_info[0], + binaries =3D [ + "nosetests-%d.%d" % (sys.version_info[0], sys.version_info[1]), - "/usr/bin/nosetests-%d" % (sys.version_info[0]), - "/usr/bin/nosetests", + "nosetests-%d" % (sys.version_info[0]), + "nosetests", ] =20 - for path in paths: - if os.path.exists(path): + for binary in binaries: + path =3D distutils.spawn.find_executable(binary) + if path !=3D None: return path =20 raise Exception("Cannot find any nosetests binary") --=20 2.13.5 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list