Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 828550 - dev-embedded/arduino-ctags-20161123-r1: stabilisation (was: dev-embedded/arduino-ctags-20161123 - general.h: error: missing binary operator before token)
Summary: dev-embedded/arduino-ctags-20161123-r1: stabilisation (was: dev-embedded/ardu...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Stabilization (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Embedded Gentoo Team
URL:
Whiteboard:
Keywords: CC-ARCHES, PATCH
Depends on:
Blocks: glibc-2.34
  Show dependency tree
 
Reported: 2021-12-08 08:21 UTC by Toralf Förster
Modified: 2022-01-02 09:58 UTC (History)
3 users (show)

See Also:
Package list:
dev-embedded/arduino-ctags-20161123-r1
Runtime testing required: ---
nattka: sanity-check+


Attachments
emerge-info.txt (emerge-info.txt,17.26 KB, text/plain)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
dev-embedded:arduino-ctags-20161123:20211208-023231.log (dev-embedded:arduino-ctags-20161123:20211208-023231.log,8.25 KB, text/plain)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
emerge-history.txt (emerge-history.txt,330.57 KB, text/plain)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
environment (environment,17.40 KB, text/plain)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
etc.portage.tar.bz2 (etc.portage.tar.bz2,20.44 KB, application/x-bzip)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
logs.tar.bz2 (logs.tar.bz2,5.42 KB, application/x-bzip)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
temp.tar.bz2 (temp.tar.bz2,7.64 KB, application/x-bzip)
2021-12-08 08:21 UTC, Toralf Förster
no flags Details
the patch for arduino-ctags code (unused.patch,7.22 KB, patch)
2021-12-22 22:07 UTC, s.zharkoff
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2021-12-08 08:21:36 UTC
                 from args.c:17:
/usr/include/sys/cdefs.h:262:61: error: missing ')' after "__has_attribute"
  262 | #if __GNUC_PREREQ (2,7) || __glibc_has_attribute (__unused__)
      |                                                             ^
general.h:60:36: error: missing binary operator before token "("
   60 | # define __unused__  __attribute__((unused))
      |                                    ^
general.h:60:36: error: missing binary operator before token "("
   60 | # define __unused__  __attribute__((unused))

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_no_multilib_systemd-j4-20211204-193910

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-11.2.1 *
clang version 13.0.0
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/13/bin
/usr/lib/llvm/13
13.0.0
Python 3.9.9
Available Ruby profiles:
  [1]   ruby26 (with Rubygems)
  [2]   ruby27 (with Rubygems)
  [3]   ruby30 (with Rubygems) *
Available Rust versions:
  [1]   rust-bin-1.57.0 *
The following VMs are available for generation-2:
*)	AdoptOpenJDK 8.312_p07 [openjdk-bin-8]
Available Java Virtual Machines:
  [1]   openjdk-bin-8  system-vm

The Glorious Glasgow Haskell Compilation System, version 8.10.4
php cli:

  HEAD of ::gentoo
commit 671771614f120699b3e41ae8af862df2d4c02b53
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Wed Dec 8 01:34:55 2021 +0000

    2021-12-08 01:34:54 UTC

emerge -qpvO dev-embedded/arduino-ctags
[ebuild  N    ] dev-embedded/arduino-ctags-20161123
Comment 1 Toralf Förster gentoo-dev 2021-12-08 08:21:37 UTC
Created attachment 757690 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2021-12-08 08:21:38 UTC
Created attachment 757691 [details]
dev-embedded:arduino-ctags-20161123:20211208-023231.log
Comment 3 Toralf Förster gentoo-dev 2021-12-08 08:21:40 UTC
Created attachment 757692 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2021-12-08 08:21:41 UTC
Created attachment 757693 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2021-12-08 08:21:45 UTC
Created attachment 757694 [details]
etc.portage.tar.bz2
Comment 6 Toralf Förster gentoo-dev 2021-12-08 08:21:45 UTC
Created attachment 757695 [details]
logs.tar.bz2
Comment 7 Toralf Förster gentoo-dev 2021-12-08 08:21:46 UTC
Created attachment 757696 [details]
temp.tar.bz2
Comment 8 Viktar Patotski 2021-12-15 22:40:08 UTC
I have same problem. At the same time, installation of "dev-embedded/arduino-ctags-20161123" with ebuildtester passes without any issues. There must be something installed later, that breaks these "cdefs.h" file...
Comment 9 Viktar Patotski 2021-12-15 23:04:27 UTC
It seems to be related to "glibc".
sys-libs/glibc-2.34-r3 (/usr/include/sys/cdefs.h) - DO NOT compile
sys-libs/glibc-2.33-r1 (/usr/include/sys/cdefs.h) - compiles well.
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-12-16 06:59:32 UTC
hm, Debian still packages it, but no fix upstream: https://packages.debian.org/unstable/editors/arduino-ctags
Comment 11 s.zharkoff 2021-12-22 22:05:02 UTC
As I see the issue is with defining __unused__ macro in general.h header.
This is a very common name so __unused__ got defined by libc headers and this conflicting define breaks the compile.

Just replaced __unused__ with __arduino_unused__ everywhere in the code and it compiles well.
Comment 12 s.zharkoff 2021-12-22 22:07:16 UTC
Created attachment 760133 [details, diff]
the patch for arduino-ctags code

Maybe there is a better way to use sed command in the ebuild itsel - but I am not good in ebuilds , so just the idea.
Comment 13 Viktar Patotski 2021-12-22 22:17:09 UTC
just applied patch and it compiles well. I can try creating sed based patch and test if it compiles.

Thanks a lot!!
Comment 14 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-12-23 00:12:07 UTC
(In reply to s.zharkoff from comment #12)
> Created attachment 760133 [details, diff] [details, diff]
> the patch for arduino-ctags code
> 
> Maybe there is a better way to use sed command in the ebuild itsel - but I
> am not good in ebuilds , so just the idea.

lgtm. it's a hack but it's the easiest way given upstream is dead. thanks a lot!
Comment 15 Larry the Git Cow gentoo-dev 2021-12-23 00:15:53 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=612c3d433d5cc3d78ca7f48fb9e134eaefa38b7b

commit 612c3d433d5cc3d78ca7f48fb9e134eaefa38b7b
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2021-12-23 00:14:46 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2021-12-23 00:15:23 +0000

    dev-embedded/arduino-ctags: update EAPI 6 -> 8, fix build
    
    Bug: https://bugs.gentoo.org/828550
    Thanks-to: <s.zharkoff@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 .../arduino-ctags/arduino-ctags-20161123-r1.ebuild |  32 +++
 ...duino-ctags-20161123-gcc-unused-attribute.patch | 225 +++++++++++++++++++++
 2 files changed, 257 insertions(+)
Comment 16 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-01-02 05:51:40 UTC
amd64 done
Comment 17 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-01-02 09:58:49 UTC
x86 done

all arches done