]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
afsplitter: Move into its own module
authorPatrick Steinhardt <ps@pks.im>
Fri, 27 Dec 2019 15:18:37 +0000 (16:18 +0100)
committerDaniel Kiper <daniel.kiper@oracle.com>
Fri, 10 Jan 2020 13:27:49 +0000 (14:27 +0100)
While the AFSplitter code is currently used only by the luks module,
upcoming support for luks2 will add a second module that depends on it.
To avoid any linker errors when adding the code to both modules because
of duplicated symbols, this commit moves it into its own standalone
module afsplitter as a preparatory step.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/Makefile.core.def
grub-core/disk/AFSplitter.c

index 037de4023e84fc160dc588f578e3cda30a1b42fd..db346a9f47c361c8f8824b017fa6502b4b6a5d44 100644 (file)
@@ -1181,10 +1181,14 @@ module = {
   common = lib/json/json.c;
 };
 
+module = {
+  name = afsplitter;
+  common = disk/AFSplitter.c;
+};
+
 module = {
   name = luks;
   common = disk/luks.c;
-  common = disk/AFSplitter.c;
 };
 
 module = {
index f5a8ddc61f4dcf57f74aa2a0a81a14404daef630..249163ff07f7fc89493441a2135c343245d5b5ec 100644 (file)
  */
 
 #include <grub/crypto.h>
+#include <grub/dl.h>
 #include <grub/mm.h>
 #include <grub/misc.h>
 
+GRUB_MOD_LICENSE ("GPLv2+");
+
 gcry_err_code_t AF_merge (const gcry_md_spec_t * hash, grub_uint8_t * src,
                          grub_uint8_t * dst, grub_size_t blocksize,
                          grub_size_t blocknumbers);