Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 26 Apr 2017 12:00:32 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-ports-bugs@FreeBSD.org
Subject:   [Bug 218884] emulators/open-vm-tools*: breaks if libunwind installed
Message-ID:  <bug-218884-13@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D218884

            Bug ID: 218884
           Summary: emulators/open-vm-tools*: breaks if libunwind
                    installed
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: Individual Port(s)
          Assignee: freebsd-ports-bugs@FreeBSD.org
          Reporter: z7dr6ut7gs@snkmail.com

I get the following error when building open-vm-tools{,-nox11}:

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
utilBacktrace.c:156:20: error: implicit declaration of function
'_Unwind_GetCFA' is invalid in C99
      [-Werror,-Wimplicit-function-declaration]
   uintptr_t cfa =3D _Unwind_GetCFA(ctx);
                   ^
utilBacktrace.c:358:4: error: implicit declaration of function
'_Unwind_Backtrace' is invalid in C99
      [-Werror,-Wimplicit-function-declaration]
   _Unwind_Backtrace(UtilBacktraceFromPointerCallback, &data);
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

This happens if the build detects libunwind (and adds -DHAVE_LIBUNWIND_H=3D1
during build).  Reproduce by installing the libunwind port and trying to bu=
ild
open-vm-tools*.

If unwind.h is not available, you don't get the error.

Or if the libunwind port is installed, and you add -D_GNU_SOURCE, then you
don't get the error.

Or if the unwind.h is detected and you build with gcc5 or gcc6, then you do=
n't
get the error.  Those gcc ports both have an internal version of unwind.h

See also
https://lists.freebsd.org/pipermail/freebsd-virtualization/2017-January/005=
186.html

I don't think it's vital for a working open-vm-tools to have unwind enabled=
.=20
So disabling unwind at configure time seems right until all supported compi=
lers
support unwind.  There's no configure switch for --without-unwind or anythi=
ng,
so it'd be a patch against configure.

Alternately, we could pass in -D_GNU_SOURCE.

I can put together a patch.  Let me know what you think about the above and
which option seems best.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-218884-13>