Message ID | 20211018092354.2637731-3-philmd@redhat.com |
---|---|
State | New |
Headers | show |
Series | roms/edk2: Avoid cloning unused cmocka submodule | expand |
On 10/18/21 11:23, Philippe Mathieu-Daudé wrote: > The EDK2 firmware images built to test QEMU do not require > the following submodules: > > - MdeModulePkg/Universal/RegularExpressionDxe/oniguruma > - UnitTestFrameworkPkg/Library/CmockaLib/cmocka > > The only submodules required are: > > - ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 > - BaseTools/Source/C/BrotliCompress/brotli > - CryptoPkg/Library/OpensslLib/openssl > - MdeModulePkg/Library/BrotliCustomDecompressLib/brotli > > Adapt the buildsys machinery to only initialize the required > submodules. > > Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> > --- > .gitlab-ci.d/edk2.yml | 4 ++++ > roms/Makefile.edk2 | 7 ++++++- > scripts/make-release | 7 ++++++- > 3 files changed, 16 insertions(+), 2 deletions(-) > # See notes on the ".NOTPARALLEL" target and the "+" indicator in > diff --git a/scripts/make-release b/scripts/make-release > index a2a8cda33c0..a9ff933a4ca 100755 > --- a/scripts/make-release > +++ b/scripts/make-release > @@ -27,7 +27,12 @@ git submodule update --init > # don't necessarily have much control over how a submodule handles its > # submodule dependencies, so we continue to handle these on a case-by-case > # basis for now. > -(cd roms/edk2 && git submodule update --init) > +(cd roms/edk2 && \ > + git submodule update --init \ Hmm I forgot the '--' separator here. > + ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 \ > + BaseTools/Source/C/BrotliCompress/brotli \ > + CryptoPkg/Library/OpensslLib/openssl \ > + MdeModulePkg/Library/BrotliCustomDecompressLib/brotli) > popd > tar --exclude=.git -cjf ${destination}.tar.bz2 ${destination} > rm -rf ${destination} >
Cc'ing Michael, since the make-release script is not covered in any MAINTAINERS section. On 10/18/21 11:31, Philippe Mathieu-Daudé wrote: > On 10/18/21 11:23, Philippe Mathieu-Daudé wrote: >> The EDK2 firmware images built to test QEMU do not require >> the following submodules: >> >> - MdeModulePkg/Universal/RegularExpressionDxe/oniguruma >> - UnitTestFrameworkPkg/Library/CmockaLib/cmocka >> >> The only submodules required are: >> >> - ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 >> - BaseTools/Source/C/BrotliCompress/brotli >> - CryptoPkg/Library/OpensslLib/openssl >> - MdeModulePkg/Library/BrotliCustomDecompressLib/brotli >> >> Adapt the buildsys machinery to only initialize the required >> submodules. >> >> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> >> --- >> .gitlab-ci.d/edk2.yml | 4 ++++ >> roms/Makefile.edk2 | 7 ++++++- >> scripts/make-release | 7 ++++++- >> 3 files changed, 16 insertions(+), 2 deletions(-) > >> # See notes on the ".NOTPARALLEL" target and the "+" indicator in >> diff --git a/scripts/make-release b/scripts/make-release >> index a2a8cda33c0..a9ff933a4ca 100755 >> --- a/scripts/make-release >> +++ b/scripts/make-release >> @@ -27,7 +27,12 @@ git submodule update --init >> # don't necessarily have much control over how a submodule handles its >> # submodule dependencies, so we continue to handle these on a case-by-case >> # basis for now. >> -(cd roms/edk2 && git submodule update --init) >> +(cd roms/edk2 && \ >> + git submodule update --init \ > > Hmm I forgot the '--' separator here. BTW Michael since commit 9d03f5abede ("travis.yml: Remove the "Release tarball" job") we don't test make-release anymore in our CI, you might want to add some GitLab equivalent job. Regards, Phil.
diff --git a/.gitlab-ci.d/edk2.yml b/.gitlab-ci.d/edk2.yml index 62497ba47fb..2f12939d744 100644 --- a/.gitlab-ci.d/edk2.yml +++ b/.gitlab-ci.d/edk2.yml @@ -51,6 +51,10 @@ build-edk2: script: # Clone the required submodules and build EDK2 - git submodule update --init roms/edk2 - git -C roms/edk2 submodule update --init + ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 + BaseTools/Source/C/BrotliCompress/brotli + CryptoPkg/Library/OpensslLib/openssl + MdeModulePkg/Library/BrotliCustomDecompressLib/brotli - export JOBS=$(($(getconf _NPROCESSORS_ONLN) + 1)) - echo "=== Using ${JOBS} simultaneous jobs ===" - make -j${JOBS} -C roms efi 2>&1 1>edk2-stdout.log | tee -a edk2-stderr.log >&2 diff --git a/roms/Makefile.edk2 b/roms/Makefile.edk2 index a8ed3255757..fdae0b511f5 100644 --- a/roms/Makefile.edk2 +++ b/roms/Makefile.edk2 @@ -51,7 +51,12 @@ all: $(foreach flashdev,$(flashdevs),../pc-bios/edk2-$(flashdev).fd.bz2) \ # make-release/tarball scripts. submodules: if test -d edk2/.git; then \ - cd edk2 && git submodule update --init --force; \ + cd edk2 && git submodule update --init --force -- \ + ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 \ + BaseTools/Source/C/BrotliCompress/brotli \ + CryptoPkg/Library/OpensslLib/openssl \ + MdeModulePkg/Library/BrotliCustomDecompressLib/brotli \ + ; \ fi # See notes on the ".NOTPARALLEL" target and the "+" indicator in diff --git a/scripts/make-release b/scripts/make-release index a2a8cda33c0..a9ff933a4ca 100755 --- a/scripts/make-release +++ b/scripts/make-release @@ -27,7 +27,12 @@ git submodule update --init # don't necessarily have much control over how a submodule handles its # submodule dependencies, so we continue to handle these on a case-by-case # basis for now. -(cd roms/edk2 && git submodule update --init) +(cd roms/edk2 && \ + git submodule update --init \ + ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 \ + BaseTools/Source/C/BrotliCompress/brotli \ + CryptoPkg/Library/OpensslLib/openssl \ + MdeModulePkg/Library/BrotliCustomDecompressLib/brotli) popd tar --exclude=.git -cjf ${destination}.tar.bz2 ${destination} rm -rf ${destination}
The EDK2 firmware images built to test QEMU do not require the following submodules: - MdeModulePkg/Universal/RegularExpressionDxe/oniguruma - UnitTestFrameworkPkg/Library/CmockaLib/cmocka The only submodules required are: - ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3 - BaseTools/Source/C/BrotliCompress/brotli - CryptoPkg/Library/OpensslLib/openssl - MdeModulePkg/Library/BrotliCustomDecompressLib/brotli Adapt the buildsys machinery to only initialize the required submodules. Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> --- .gitlab-ci.d/edk2.yml | 4 ++++ roms/Makefile.edk2 | 7 ++++++- scripts/make-release | 7 ++++++- 3 files changed, 16 insertions(+), 2 deletions(-)