diff options
author | Konstantin Aladyshev <aladyshev22@gmail.com> | 2022-07-05 19:46:00 +0300 |
---|---|---|
committer | Konstantin Aladyshev <aladyshev22@gmail.com> | 2022-07-05 19:50:46 +0300 |
commit | 37aa4f148f37e8d39cd28d24696b79e2b3638d65 (patch) | |
tree | dd6345b33b24467594d18f31b5375fc24283f69e /Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp | |
parent | 0ecb02e19a24e5c69f08462b535d98e5ea1748cf (diff) | |
download | UEFI-Lessons-37aa4f148f37e8d39cd28d24696b79e2b3638d65.tar.gz UEFI-Lessons-37aa4f148f37e8d39cd28d24696b79e2b3638d65.tar.bz2 UEFI-Lessons-37aa4f148f37e8d39cd28d24696b79e2b3638d65.zip |
Add build tools lesson
Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com>
Diffstat (limited to 'Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp')
2 files changed, 45 insertions, 0 deletions
diff --git a/Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp/BuildOptionsApp.c b/Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp/BuildOptionsApp.c new file mode 100644 index 0000000..dc97c48 --- /dev/null +++ b/Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp/BuildOptionsApp.c @@ -0,0 +1,22 @@ +#include <Library/UefiBootServicesTableLib.h> +#include <Library/UefiLib.h> + +EFI_STATUS +EFIAPI +UefiMain ( + IN EFI_HANDLE ImageHandle, + IN EFI_SYSTEM_TABLE *SystemTable + ) +{ + #ifdef MY_DEBUG + Print(L"MY_DEBUG is defined\n"); + #endif + #ifdef MY_RELEASE + Print(L"MY_RELEASE is defined\n"); + #endif + #ifdef MY_ALL_TARGETS + Print(L"MY_ALL_TARGETS is defined\n"); + #endif + + return EFI_SUCCESS; +} diff --git a/Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp/BuildOptionsApp.inf b/Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp/BuildOptionsApp.inf new file mode 100644 index 0000000..a0581f1 --- /dev/null +++ b/Lessons_uncategorized/Lesson_Build_tools/UefiLessonsPkg/BuildOptionsApp/BuildOptionsApp.inf @@ -0,0 +1,23 @@ +[Defines] + INF_VERSION = 1.25 + BASE_NAME = BuildOptionsApp + FILE_GUID = 311c8fac-737c-436a-9a73-a66b0eae722d + MODULE_TYPE = UEFI_APPLICATION + VERSION_STRING = 1.0 + ENTRY_POINT = UefiMain + +[Sources] + BuildOptionsApp.c + +[Packages] + MdePkg/MdePkg.dec + +[LibraryClasses] + UefiApplicationEntryPoint + UefiLib + +[BuildOptions] + RELEASE_GCC5_X64_CC_FLAGS = "-DMY_RELEASE" + DEBUG_GCC5_X64_CC_FLAGS = "-DMY_DEBUG" + *_GCC5_X64_CC_FLAGS = "-DMY_ALL_TARGETS" + |