Bug 202082

Summary: emulators/dynamips-community: port fails to build on recent stable/10 (amd64)
Product: Ports & Packages Reporter: michiel
Component: Individual Port(s)Assignee: Mathieu Arnold <mat>
Status: Closed FIXED    
Severity: Affects Only Me CC: pavelivolkov
Priority: --- Flags: bugzilla: maintainer-feedback? (pavelivolkov)
Version: Latest   
Hardware: amd64   
OS: Any   
Attachments:
Description Flags
portmaster output
none
Add directory for the "libelf" library installed from ports. pavelivolkov: maintainer-approval+

Description michiel 2015-08-04 17:22:52 UTC
Created attachment 159543 [details]
portmaster output

Recently port emulators/dynamips-community was upgraded to 0.2.15.
This port does not appear to build on my system (stable/10 amd64)

The error message displayed is

load_elf_image: elf_begin: Request error: invalid ELF_C_* argument

uname -a

FreeBSD charlemagne.a43.boland.org 10.2-PRERELEASE FreeBSD 10.2-PRERELEASE #0 r286284: Tue Aug  4 18:15:35 CEST 2015     root@charlemagne.a43.boland.org:/usr/obj/usr/src/sys/CHARLEMAGNE  amd64
Comment 1 Pavel Volkov 2015-08-08 13:26:24 UTC
Created attachment 159667 [details]
Add directory for the "libelf" library installed from ports.
Comment 2 Pavel Volkov 2015-08-08 13:48:24 UTC
Hello.

If you installed the 'devel/libelf' port - you have 2 the library.
With a different header file:
- The system: '/usr/src/lib/libelf'.
  Header file '/usr/include/libelf.h' having the enumeration:
  typedef enum {
        ELF_C_NULL = 0,
        ELF_C_CLR,
        ELF_C_FDDONE,
        ELF_C_FDREAD,
        ELF_C_RDWR,
        ELF_C_READ,
        ELF_C_SET,
        ELF_C_WRITE,
        ELF_C_NUM
  } Elf_Cmd;
  
- And, installed from the port: '/usr/local/include/libelf/libelf.h'.
  With enumeration:
  typedef enum {
    ELF_C_NULL = 0,     /* must be first, 0 */
    ELF_C_READ,
    ELF_C_WRITE,
    ELF_C_CLR,
    ELF_C_SET,
    ELF_C_FDDONE,
    ELF_C_FDREAD,
    ELF_C_RDWR,
    ELF_C_NUM           /* must be last */
  } Elf_Cmd;

Having different order of the elements.

In cmake used by header from the system library,
and library file from the port.

Thank you.
Comment 3 michiel 2015-08-14 23:49:57 UTC
I confirm that this patch makes the port build again.
Comment 4 commit-hook freebsd_committer 2015-10-21 14:18:13 UTC
A commit references this bug:

Author: mat
Date: Wed Oct 21 14:17:07 UTC 2015
New revision: 399917
URL: https://svnweb.freebsd.org/changeset/ports/399917

Log:
  Fix on recent stable/10.

  PR:		202082
  Submitted by:	maintainer
  Sponsored by:	Absolight

Changes:
  head/emulators/dynamips-community/Makefile