[Buildroot] [PATCH 1/1] package/taglib: fix build on sparc

Arnout Vandecappelle arnout at mind.be
Thu Dec 16 19:09:24 UTC 2021



On 15/12/2021 18:29, Fabrice Fontaine wrote:
> Fix the following build failure on sparc raised since bump to version
> 1.12 in commit b4bdf704fea59db81433bbc07585e4c4db258d9a:
> 
> /home/giuliobenetti/autobuild/run/instance-3/output-1/build/taglib-1.12/taglib/toolkit/trefcounter.cpp:55:21: error: duplicate 'volatile'
>     55 | # define ATOMIC_INT volatile int
>        |                     ^~~~~~~~
> 
> Fixes:
>   - http://autobuild.buildroot.org/results/387feeb6bcc190b3908e405ba5f8a888d7e1f348
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice at gmail.com>

  Applied to master, thanks.

  Regards,
  Arnout

> ---
>   ...e-on-systems-without-HAVE_GCC_ATOMIC.patch | 34 +++++++++++++++++++
>   1 file changed, 34 insertions(+)
>   create mode 100644 package/taglib/0001-Fix-error-duplicate-volatile-on-systems-without-HAVE_GCC_ATOMIC.patch
> 
> diff --git a/package/taglib/0001-Fix-error-duplicate-volatile-on-systems-without-HAVE_GCC_ATOMIC.patch b/package/taglib/0001-Fix-error-duplicate-volatile-on-systems-without-HAVE_GCC_ATOMIC.patch
> new file mode 100644
> index 0000000000..d8af73cb08
> --- /dev/null
> +++ b/package/taglib/0001-Fix-error-duplicate-volatile-on-systems-without-HAVE_GCC_ATOMIC.patch
> @@ -0,0 +1,34 @@
> +From 1d24bd3399f2284104cbe87d017f87325b1797ab Mon Sep 17 00:00:00 2001
> +From: Oleg Antonyan <oleg.b.antonyan at gmail.com>
> +Date: Thu, 13 May 2021 16:41:35 +0200
> +Subject: [PATCH] =?UTF-8?q?Fix=20"error:=20duplicate=20=E2=80=98volatile?=
> + =?UTF-8?q?=E2=80=99"=20on=20systems=20without=20HAVE=5FGCC=5FATOMIC=20in?=
> + =?UTF-8?q?=201.12=20(#1012)?=
> +MIME-Version: 1.0
> +Content-Type: text/plain; charset=UTF-8
> +Content-Transfer-Encoding: 8bit
> +
> +* fix error: duplicate volatile
> +
> +* fix volatile ATOMIC_INT in constructor
> +
> +[Retrieved from:
> +https://github.com/taglib/taglib/commit/1d24bd3399f2284104cbe87d017f87325b1797ab]
> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice at gmail.com>
> +---
> + taglib/toolkit/trefcounter.cpp | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/taglib/toolkit/trefcounter.cpp b/taglib/toolkit/trefcounter.cpp
> +index 18cb596c0..5b089abf9 100644
> +--- a/taglib/toolkit/trefcounter.cpp
> ++++ b/taglib/toolkit/trefcounter.cpp
> +@@ -52,7 +52,7 @@
> + # define ATOMIC_INC(x) __sync_add_and_fetch(&x, 1)
> + # define ATOMIC_DEC(x) __sync_sub_and_fetch(&x, 1)
> + #else
> +-# define ATOMIC_INT volatile int
> ++# define ATOMIC_INT int
> + # define ATOMIC_INC(x) (++x)
> + # define ATOMIC_DEC(x) (--x)
> + #endif
> 



More information about the buildroot mailing list