Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1lRF39-0001sv-FS for mharc-grub-devel@gnu.org; Tue, 30 Mar 2021 10:08:55 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53412) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lRF33-0001pn-7J for grub-devel@gnu.org; Tue, 30 Mar 2021 10:08:50 -0400 Received: from mail-pj1-x102d.google.com ([2607:f8b0:4864:20::102d]:39708) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lRF2t-0004be-NF for grub-devel@gnu.org; Tue, 30 Mar 2021 10:08:49 -0400 Received: by mail-pj1-x102d.google.com with SMTP id ot17-20020a17090b3b51b0290109c9ac3c34so9517396pjb.4 for ; Tue, 30 Mar 2021 07:08:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axtens.net; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=DPflfXMw5fn6d4mKlFrys2PYlT+pnCkFdp2npamcZs0=; b=pGw3hygaIP+ComQ0Xcdnudq/KtqiZkclFdzmRJQ3m5tkmbhH5nF5e0PjLbJ6F8Blyw a0RCmhF8rf/9ZUanl62ttFLUfxQiTnDt8Rhn5yPEMw5AHGO/2o8dMFtnlgDU7/KDm0mv Dvn3N8gZJoJdLG9JU8dYOh0OsCTnXGbHRhZhY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=DPflfXMw5fn6d4mKlFrys2PYlT+pnCkFdp2npamcZs0=; b=Td3O80+nPhqT0MN5DBfpKNEgy0qwhbkh0oa9svz6vGstzB61FUk/75KK8LVO/RXNGn 6sqFOaOKU5Dqdc56MrC4PYbe6SyHw7f8PFqTbxafesCLrBh2HgY1NilP3mkbhO7UF09O Vqg595I0+WdK5ZovKKXXZfN9xHfEXbNXl2ICx/NLjL49O5YDgOepSzeCtlDra1HolYCH 5fPzuL+p+iQDHYGJrr/d8Fpk8IWGfgP0yGkjStnkAacRgPUzSAt60qRiAzh4NPIwobrQ 9U+KSWaONHhxZBE8oHLA1jH49St0dvOPG5IXbz3hkr9pZjxfJVJ6XjggxekwtJPACR+1 QqRA== X-Gm-Message-State: AOAM5300rZz9lY34mQD3FOblaew30vkYZ9YleY3iRhxgSUn77khWemP4 fItDNDFiXY+YSGYLEAqQQVyA1undFpLoFg== X-Google-Smtp-Source: ABdhPJwIfSdQDv1pd4zgmx1j0dU9LoP1Lw0z6F6C9nh9OUdcoRAFHVZXtc6rkV0BlTHI80fpginQMQ== X-Received: by 2002:a17:902:eac3:b029:e6:f010:6ecb with SMTP id p3-20020a170902eac3b02900e6f0106ecbmr33646394pld.37.1617113318092; Tue, 30 Mar 2021 07:08:38 -0700 (PDT) Received: from localhost (2001-44b8-111e-5c00-cc4e-3d4e-f51c-bb52.static.ipv6.internode.on.net. [2001:44b8:111e:5c00:cc4e:3d4e:f51c:bb52]) by smtp.gmail.com with ESMTPSA id c2sm20601387pfb.121.2021.03.30.07.08.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Mar 2021 07:08:37 -0700 (PDT) From: Daniel Axtens To: grub-devel@gnu.org Cc: rashmica.g@gmail.com, alastair@d-silva.org, Daniel Axtens Subject: [PATCH 11/19] libtasn1: compile into asn1 module Date: Wed, 31 Mar 2021 01:07:36 +1100 Message-Id: <20210330140744.176698-12-dja@axtens.net> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210330140744.176698-1-dja@axtens.net> References: <20210330140744.176698-1-dja@axtens.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:20::102d; envelope-from=dja@axtens.net; helo=mail-pj1-x102d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 30 Mar 2021 14:08:51 -0000 Create a wrapper file that specifies the module license. Set up the makefile so it is built. Signed-off-by: Daniel Axtens --- grub-core/Makefile.core.def | 15 +++++++++++++++ grub-core/lib/libtasn1_wrap/wrap.c | 26 ++++++++++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 grub-core/lib/libtasn1_wrap/wrap.c diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def index 915287d44c13..6fbae150c687 100644 --- a/grub-core/Makefile.core.def +++ b/grub-core/Makefile.core.def @@ -2535,3 +2535,18 @@ module = { common = commands/i386/wrmsr.c; enable = x86; }; + +module = { + name = asn1; + common = lib/libtasn1/lib/decoding.c; + common = lib/libtasn1/lib/coding.c; + common = lib/libtasn1/lib/element.c; + common = lib/libtasn1/lib/structure.c; + common = lib/libtasn1/lib/parser_aux.c; + common = lib/libtasn1/lib/gstr.c; + common = lib/libtasn1/lib/errors.c; + common = lib/libtasn1_wrap/wrap.c; + cflags = '$(CFLAGS_POSIX) $(CFLAGS_GNULIB)'; + // -Wno-type-limits comes from libtasn1's configure.ac + cppflags = '$(CPPFLAGS_POSIX) $(CPPFLAGS_GNULIB) -I$(srcdir)/lib/libtasn1/lib -Wno-type-limits'; +}; diff --git a/grub-core/lib/libtasn1_wrap/wrap.c b/grub-core/lib/libtasn1_wrap/wrap.c new file mode 100644 index 000000000000..622ba942e33f --- /dev/null +++ b/grub-core/lib/libtasn1_wrap/wrap.c @@ -0,0 +1,26 @@ +/* + * GRUB -- GRand Unified Bootloader + * Copyright (C) 2020 IBM Corporation + * + * GRUB 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. + * + * GRUB 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 GRUB. If not, see . + */ + +#include + +/* + * libtasn1 is provided under LGPL2.1+, which is compatible + * with GPL3+. As Grub as a whole is under GPL3+, this module + * is therefore under GPL3+ also. + */ +GRUB_MOD_LICENSE ("GPLv3+"); -- 2.27.0