Merge branch '2021-03-28-assorted-bugfixes'
diff --git a/Makefile b/Makefile
index e9b9c15..7d73062 100644
--- a/Makefile
+++ b/Makefile
@@ -324,11 +324,6 @@
KBUILD_HOSTCFLAGS += $(call os_x_before, 10, 4, "-traditional-cpp")
KBUILD_HOSTLDFLAGS += $(call os_x_before, 10, 5, "-multiply_defined suppress")
-# since Lion (10.7) ASLR is on by default, but we use linker generated lists
-# in some host tools which is a problem then ... so disable ASLR for these
-# tools
-KBUILD_HOSTLDFLAGS += $(call os_x_before, 10, 7, "", "-Xlinker -no_pie")
-
# macOS Mojave (10.14.X)
# Undefined symbols for architecture x86_64: "_PyArg_ParseTuple"
KBUILD_HOSTLDFLAGS += $(call os_x_after, 10, 14, "-lpython -dynamclib", "")
diff --git a/include/dm/test.h b/include/dm/test.h
index 6ac6672..c5a9610 100644
--- a/include/dm/test.h
+++ b/include/dm/test.h
@@ -6,6 +6,8 @@
#ifndef __DM_TEST_H
#define __DM_TEST_H
+struct udevice;
+
/**
* struct dm_test_cdata - configuration data for test instance
*
diff --git a/test/print_ut.c b/test/print_ut.c
index a456a44..5b0a46d 100644
--- a/test/print_ut.c
+++ b/test/print_ut.c
@@ -6,10 +6,8 @@
#define DEBUG
#include <common.h>
-#if CONFIG_IS_ENABLED(EFI_LOADER) && !defined(API_BUILD)
#include <command.h>
#include <efi_api.h>
-#endif
#include <display_options.h>
#include <log.h>
#include <version.h>
diff --git a/tools/imagetool.h b/tools/imagetool.h
index 8726792..2801ea9 100644
--- a/tools/imagetool.h
+++ b/tools/imagetool.h
@@ -273,14 +273,14 @@
#define INIT_SECTION(name) do { \
unsigned long name ## _len; \
- char *__cat(pstart_, name) = getsectdata("__TEXT", \
+ char *__cat(pstart_, name) = getsectdata("__DATA", \
#name, &__cat(name, _len)); \
char *__cat(pstop_, name) = __cat(pstart_, name) + \
__cat(name, _len); \
__cat(__start_, name) = (void *)__cat(pstart_, name); \
__cat(__stop_, name) = (void *)__cat(pstop_, name); \
} while (0)
-#define SECTION(name) __attribute__((section("__TEXT, " #name)))
+#define SECTION(name) __attribute__((section("__DATA, " #name)))
struct image_type_params **__start_image_type, **__stop_image_type;
#else