From nobody Fri May 3 08:51:32 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1588247089; cv=none; d=zohomail.com; s=zohoarc; b=aLR3/W0Q68H6J5GjpwdOrhwuBiWB0AGM9o0MvUD27QvyVgSFfaecs9D13LwLUkdE7B5VZYBPqMewh8elVLEqYIBIThOHffmk8K6JDDDqnAApq+ppfFWexfRPetga1rm/aOjHvInWeDBmEa1qawTiieW/C9SKgGvwyUYCmI7o5Ho= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1588247089; h=Content-Type:Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=rb+0RIJedd4xngggYpwKO4/cC5SHBwie1tTKH4P52bM=; b=OnAMGLiCAgyPhnX9pDLNTkRJWevtHN8FUeuy8EKn4Qne+8KCIFlUyWPuAtsuLE/odSp8p+bYbWfihwOauYGoOUw2jfiWNv6S0a0c0Ild6kFzGsggrxkmfacdcxNFuyFc3XRxs9qBjOW14Q7cvAuWdn39oSQSwV9eMpk85y5uiss= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1588247089854388.89825278859394; Thu, 30 Apr 2020 04:44:49 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-332-YDCaxZ9dPLCnXFoB97Ciog-1; Thu, 30 Apr 2020 07:44:45 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id F35EF468; Thu, 30 Apr 2020 11:44:39 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id EDFB45EDE5; Thu, 30 Apr 2020 11:44:38 +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 075C14CAA0; Thu, 30 Apr 2020 11:44:38 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 03UBiajX009624 for ; Thu, 30 Apr 2020 07:44:36 -0400 Received: by smtp.corp.redhat.com (Postfix) id E9DE65D9F5; Thu, 30 Apr 2020 11:44:36 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.36.110.44]) by smtp.corp.redhat.com (Postfix) with ESMTP id BBFDF5D9C5; Thu, 30 Apr 2020 11:44:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1588247088; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=rb+0RIJedd4xngggYpwKO4/cC5SHBwie1tTKH4P52bM=; b=aVSk6LoZ56KGlQdiXQ6bZ/PcEihkqFPEOs3ELmM8H67iaKbzb+OZmu1K+fIYL3nu9pH4dB bcXpdiSA34eoqx3mG2hUhMJ1NRc6j0idKWSb5Er1GMf1Jd1/gxVbZ1yySlD5jH2QAVa6R3 6pGTDvxMAFUYP0Jm4TpqUb/2qjpQLwM= X-MC-Unique: YDCaxZ9dPLCnXFoB97Ciog-1 From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= To: libvir-list@redhat.com Subject: [libvirt-ci PATCH v2] guests: introduce libvirt+dist and libvirt+minimal projects Date: Thu, 30 Apr 2020 12:44:31 +0100 Message-Id: <20200430114431.2183429-1-berrange@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: libvir-list@redhat.com 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: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The language bindings have traditionally built against a full libvirt, however, this is serious overkill because all they should really need most of the time is access to the main API, and the test driver if they want to run functional tests. The full libvirt build with virt drivers is only needed for integration testing which most bindings won't do. Thus this introduces a new project "libvirt+minimal" which lists the bare minimum dependencies required to build libvirt. Taking libvirt-perl as an example, if creating a container using the current "libvirt,libvirt-perl" project set, the result with 1.4 GB in size for Fedora 31. With the "libvirt+minimal,libvirt-perl" set, the size is just 777 MB. Some projects also wish to have the ability to build against the distro provided libvirt instead of the latest git master, and for this purpose a "libvirt+dist" project is defined which pulls in the package needed for building against the distro libvirt. Thus when building any downstream project there is now a choice of building it against "libvirt" (full git) or "libvirt+minimal" (minimal git) or "libvirt+dist" (prebuilt distro). The same can be added later for example "libvirt-perl+dist" to refer to the distro provided perl binding. In the lcitool dockerfile command, there is a check that the requested project is configured against the requested host. These new projects are not listed against any host, because we don't want them installed by default in the VMs. Thus the dockerfile check is no longer valid and is removed. Whomever is invoking lcitool knows what combination they want and whether it will work. Signed-off-by: Daniel P. Berrang=C3=A9 --- In v2: - Use "+suffix" syntax for new projects - Rename new package to "libvirt" guests/lcitool | 7 ------- guests/vars/mappings.yml | 5 +++++ guests/vars/projects/libvirt+dist.yml | 3 +++ guests/vars/projects/libvirt+minimal.yml | 12 ++++++++++++ 4 files changed, 20 insertions(+), 7 deletions(-) create mode 100644 guests/vars/projects/libvirt+dist.yml create mode 100644 guests/vars/projects/libvirt+minimal.yml diff --git a/guests/lcitool b/guests/lcitool index 0c89e13..abc87d2 100755 --- a/guests/lcitool +++ b/guests/lcitool @@ -1007,13 +1007,6 @@ class Application: for project in projects: if project.rfind("+mingw") >=3D 0: raise Exception("Obsolete syntax, please use --cross-arch") - if project not in facts["projects"]: - raise Exception( - "Host {} doesn't support project {}".format( - host, - project, - ) - ) =20 varmap =3D self._dockerfile_build_varmap(facts, mappings, pip_mapp= ings, projects, cross_arch) self._dockerfile_format(facts, cross_arch, varmap) diff --git a/guests/vars/mappings.yml b/guests/vars/mappings.yml index 4a19fb4..9dcad46 100644 --- a/guests/vars/mappings.yml +++ b/guests/vars/mappings.yml @@ -450,6 +450,11 @@ mappings: rpm: libuuid-devel cross-policy-deb: foreign =20 + libvirt: + rpm: libvirt-devel + deb: libvirt-dev + pkg: libvirt + libxml2: deb: libxml2-dev pkg: libxml2 diff --git a/guests/vars/projects/libvirt+dist.yml b/guests/vars/projects/l= ibvirt+dist.yml new file mode 100644 index 0000000..1fc1b2c --- /dev/null +++ b/guests/vars/projects/libvirt+dist.yml @@ -0,0 +1,3 @@ +--- +packages: + - libvirt diff --git a/guests/vars/projects/libvirt+minimal.yml b/guests/vars/project= s/libvirt+minimal.yml new file mode 100644 index 0000000..96335f2 --- /dev/null +++ b/guests/vars/projects/libvirt+minimal.yml @@ -0,0 +1,12 @@ +--- +packages: + - glib2 + - gnutls + - libnl3 + - libnlroute3 + - libtirpc + - libxml2 + - python3-docutils + - rpcgen + - xmllint + - xsltproc --=20 2.25.4