!4 Fix-link-failure-with-gcc-10

From: @yangcheng1203
Reviewed-by: @zzm_567,@yanan-rock
Signed-off-by: @yanan-rock
This commit is contained in:
openeuler-ci-bot 2021-07-30 07:42:08 +00:00 committed by Gitee
commit 9d13cff62f
2 changed files with 34 additions and 1 deletions

View File

@ -0,0 +1,28 @@
From edcbe5f52ddfceee3d66d69bbcebbceac06b6d0d Mon Sep 17 00:00:00 2001
From: Adam Jackson <ajax@redhat.com>
Date: Tue, 4 Feb 2020 16:38:06 -0500
Subject: [PATCH xf86-video-amdgpu] Fix link failure with gcc 10
Without the 'extern' this looks like a definition not just a
declaration, in every file that includes the header. gcc 10 is stricter
about this kind of multiple definition.
---
src/drmmode_display.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/drmmode_display.h b/src/drmmode_display.h
index 96eaef0..8cd8a0a 100644
--- a/src/drmmode_display.h
+++ b/src/drmmode_display.h
@@ -262,7 +262,7 @@ Bool drmmode_wait_vblank(xf86CrtcPtr crtc, drmVBlankSeqType type,
uint64_t *ust, uint32_t *result_seq);
-miPointerSpriteFuncRec drmmode_sprite_funcs;
+extern miPointerSpriteFuncRec drmmode_sprite_funcs;
#endif
--
1.8.3.1

View File

@ -4,12 +4,14 @@
Name: xorg-x11-drv-ati
Version: 19.1.0
Release: 2
Release: 3
Summary: Xorg X11 ati video driver
License: MIT
URL: https://www.x.org
Source0: https://www.x.org/pub/individual/driver/xf86-video-ati-%{version}.tar.bz2
Patch6000: backport-Fix-link-failure-with-gcc-10.patch
BuildRequires: pkgconfig(gbm) >= 10.6 libdrm-devel kernel-headers
BuildRequires: automake autoconf libtool pkgconfig xorg-x11-util-macros
BuildRequires: libudev-devel xorg-x11-glamor-devel xorg-x11-server-devel
@ -49,6 +51,9 @@ make check
%{_mandir}/man4/*.4*
%changelog
* Fri Jul 30 2021 yangcheng <yangcheng87@huawei.com> - 19.1.0-3
- Fix compilation failure caused by gcc
* Fri Mar 13 2020 openEuler Buildteam <buildteam@openeuler.org> - 19.1.0-2
- Type:enhancement
- Id:NA