From patchwork Mon Sep 13 11:22:06 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adolf Belka X-Patchwork-Id: 4704 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4H8lFN1RcPz3xVb for ; Wed, 15 Sep 2021 15:56:24 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4H8lFL5Q6wz13n; Wed, 15 Sep 2021 15:56:22 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4H8lFL3ngRz2xcv; Wed, 15 Sep 2021 15:56:22 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4H8lFJ4Q1vz2xKZ for ; Wed, 15 Sep 2021 15:56:20 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4H7PGH3dZQzsf; Mon, 13 Sep 2021 11:22:31 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1631532151; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=zRhXC0hDXp2ZfKeFKVxPAzoLedwUkHedT1WgDx7q+2Y=; b=RtYRI/BvQrei90xQLkm3TphwaO6qUvA1WwirgUC1eSdFFEBMQID7GiQnt8Q5I8aXSjWXbM QcTAeiC1HWfNdkCQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1631532151; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=zRhXC0hDXp2ZfKeFKVxPAzoLedwUkHedT1WgDx7q+2Y=; b=urSVkcsOP8ywxh4i8zlGxcZBunaHP9BaBVuxZmu4ZTUAdi9ONiQCU64N0+EiKYYhzrjOD4 LTEQ5PAldnw6PkBnBw05O3dGD2JIHP9q4Ons+v7FcHvfM9OMCI98Dy9E/K3zItrbZRu5Vd SmEdCoA2qRhQV9Zrz8Ne8DoB+SaslZHx84HHoKMlge8UvJJg0bSyD0InHZxAhhEe0jBL9T CsqJcmIuaZRBw7fNTSFoXYV0cUNNxbOMizq83S6T1bz+Z8BbhBddHfvOHk85U50lfYyC9G wnxiFJ1FYznuwp49opkvAEIbjMuOwYO+KE5VIv1D++UTUaTv49xcMfltlwrthg== From: Adolf Belka To: development@lists.ipfire.org Subject: [PATCH v2 2/2] libyang: New dependency for frr build Date: Mon, 13 Sep 2021 13:22:06 +0200 Message-Id: <20210913112206.71982-2-adolf.belka@ipfire.org> In-Reply-To: <20210913112206.71982-1-adolf.belka@ipfire.org> References: <20210913112206.71982-1-adolf.belka@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" - Impementation of libyang-2.0.7 as a dependency for the build of frr - Creation of rootfile with all entries commented out so that it is only used for the build libyang is a YANG data modelling language parser and toolkit written (and providing API) in C.In the future if there is demand to use these functions in frr then this package may need to be moved from a build only option to a dependency for frr providing the yang libraries. - Added into make.sh just before frr Signed-off-by: Adolf Belka --- config/rootfiles/common/libyang | 31 ++++++++++++ lfs/libyang | 88 +++++++++++++++++++++++++++++++++ make.sh | 1 + 3 files changed, 120 insertions(+) create mode 100644 config/rootfiles/common/libyang create mode 100644 lfs/libyang diff --git a/config/rootfiles/common/libyang b/config/rootfiles/common/libyang new file mode 100644 index 000000000..433b09fc8 --- /dev/null +++ b/config/rootfiles/common/libyang @@ -0,0 +1,31 @@ +#usr/bin/yanglint +#usr/bin/yangre +#usr/include/libyang +#usr/include/libyang/config.h +#usr/include/libyang/context.h +#usr/include/libyang/dict.h +#usr/include/libyang/in.h +#usr/include/libyang/libyang.h +#usr/include/libyang/log.h +#usr/include/libyang/out.h +#usr/include/libyang/parser_data.h +#usr/include/libyang/parser_schema.h +#usr/include/libyang/plugins.h +#usr/include/libyang/plugins_exts.h +#usr/include/libyang/plugins_exts_compile.h +#usr/include/libyang/plugins_exts_print.h +#usr/include/libyang/plugins_types.h +#usr/include/libyang/printer_data.h +#usr/include/libyang/printer_schema.h +#usr/include/libyang/set.h +#usr/include/libyang/tree.h +#usr/include/libyang/tree_data.h +#usr/include/libyang/tree_edit.h +#usr/include/libyang/tree_schema.h +#usr/include/libyang/version.h +#usr/lib/libyang.so +#usr/lib/libyang.so.2 +#usr/lib/libyang.so.2.1.4 +#usr/lib/pkgconfig +#usr/lib/pkgconfig/libyang.pc +#usr/share/man/man1/yanglint.1 diff --git a/lfs/libyang b/lfs/libyang new file mode 100644 index 000000000..0d7149333 --- /dev/null +++ b/lfs/libyang @@ -0,0 +1,88 @@ +############################################################################### +# # +# IPFire.org - A linux based firewall # +# Copyright (C) 2007-2018 IPFire Team # +# # +# This program is free software: you can redistribute it and/or modify # +# it under the terms of the GNU General Public License as published by # +# the Free Software Foundation, either version 3 of the License, or # +# (at your option) any later version. # +# # +# This program is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU General Public License for more details. # +# # +# You should have received a copy of the GNU General Public License # +# along with this program. If not, see . # +# # +############################################################################### + +############################################################################### +# Definitions +############################################################################### + +include Config + +VER = 2.0.7 + +THISAPP = libyang-$(VER) +DL_FILE = $(THISAPP).tar.gz +DL_FROM = $(URL_IPFIRE) +DIR_APP = $(DIR_SRC)/$(THISAPP) +TARGET = $(DIR_INFO)/$(THISAPP) + +DEPS = + +CFLAGS += -fcommon + +############################################################################### +# Top-level Rules +############################################################################### + +objects = $(DL_FILE) + +$(DL_FILE) = $(DL_FROM)/$(DL_FILE) + +$(DL_FILE)_MD5 = 012ad174525527d5a5badfe91ddb8694 + +install : $(TARGET) + +check : $(patsubst %,$(DIR_CHK)/%,$(objects)) + +download :$(patsubst %,$(DIR_DL)/%,$(objects)) + +md5 : $(subst %,%_MD5,$(objects)) + +dist: + @$(PAK) + +############################################################################### +# Downloading, checking, md5sum +############################################################################### + +$(patsubst %,$(DIR_CHK)/%,$(objects)) : + @$(CHECK) + +$(patsubst %,$(DIR_DL)/%,$(objects)) : + @$(LOAD) + +$(subst %,%_MD5,$(objects)) : + @$(MD5) + +############################################################################### +# Installation Details +############################################################################### + +$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) + @$(PREBUILD) + @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE) + $(UPDATE_AUTOMAKE) + cd $(DIR_APP) && mkdir build + cd $(DIR_APP)/build && cmake $(DIR_APP) \ + -DCMAKE_INSTALL_PREFIX=/usr + cd $(DIR_APP)/build && make $(MAKETUNING) + cd $(DIR_APP)/build && make install + @rm -rf $(DIR_APP) + @$(POSTBUILD) + diff --git a/make.sh b/make.sh index a44a6e4bc..8b97b24df 100755 --- a/make.sh +++ b/make.sh @@ -1574,6 +1574,7 @@ buildipfire() { lfsmake2 ipset lfsmake2 dnsdist lfsmake2 bird + lfsmake2 libyang lfsmake2 frr lfsmake2 dmidecode lfsmake2 mcelog