tianocore / containers

Repository to maintain and manage edk2 containers
Other
20 stars 25 forks source link

fix:Correcting the way of deleting the qemu-build file #75

Closed yishangzhang closed 1 year ago

yishangzhang commented 1 year ago

Description

After completing the qemu build and install, you need to enter the parent folder and then perform the delete operation. Previously, it was because of the -f option of the rm command, so even if the file was not successfully deleted, there would be no error. In fact, the qemu-build folder was not deleted before.

Containers Affected

Fedora-35
Fedora-37
Ubuntu-20
Ubuntu-22
yishangzhang commented 1 year ago

Hello, while using qemu in ubuntu:20 dev, I accidentally discovered that the qemu-build folder was not deleted. Upon inspecting the Dockerfile source code, I found that the deletion operation for qemu-build was not successful. I also noticed this issue in other Dockerfiles, so I submitted a pull request to fix it. If this change is not deemed appropriate, please close it.

yishangzhang commented 1 year ago

I encountered an issue during the build process of Fedora 37, which doesn't seem to be caused by the code changes I made. Based on the build log https://github.com/tianocore/containers/actions/runs/5015850879/jobs/8991963750?pr=75 and using a newly built Fedora 37, it appears that the issue is related to this version define. https://github.com/tianocore/containers/blob/main/Fedora-37/Dockerfile#L20

FROM registry.fedoraproject.org/fedora:37 AS build
ARG GCC_VERSION=12.2.1-4.fc37
ARG GCC_VERSION_CROSS=12.2.1-2.fc37

However, as I'm not familiar with Fedora, I would like to know if it's feasible to switch to this version

[root@414e313b6e60 /]# dnf       --assumeyes       --nodocs       --setopt=install_weak_deps=0       install  gcc-c++-12.2.1-4.fc37
Last metadata expiration check: 0:00:13 ago on Thu May 18 16:18:30 2023.
No match for argument: gcc-c++-12.2.1-4.fc37
Error: Unable to find a match: gcc-c++-12.2.1-4.fc37
[root@414e313b6e60 /]# dnf list  gcc-c++
Last metadata expiration check: 0:03:55 ago on Thu May 18 16:18:30 2023.
Available Packages
gcc-c++.i686                                                                                         12.2.1-2.fc37                                                                                       fedora
gcc-c++.x86_64                                                                                       12.3.1-1.fc37                                                                                       updates
cfernald commented 1 year ago

Hey, I think we are okay to move forward to 12.3.1-1.fc37 though it may be good to get @osteffenrh to comment since it would be good to make the compiler moves at decided points instead of being forced in this way.

yishangzhang commented 1 year ago

Hey, I think we are okay to move forward to 12.3.1-1.fc37 though it may be good to get @osteffenrh to comment since it would be good to make the compiler moves at decided points instead of being forced in this way.

Thanks for your approved, so version management of packages in Fedora will be decided by osteffenrh.

osteffenrh commented 1 year ago

Thanks for fixing this!

I updated the gcc versions in https://github.com/tianocore/containers/pull/72 (now merged). You can rebase to the main branch and it should work.

yishangzhang commented 1 year ago

hello! Is there anything else that needs to be changed in this PR?