Bug 108515

Summary: devel/libusb : fix build on amd64
Product: Ports & Packages Reporter: Rene Ladan <r.c.ladan>
Component: Individual Port(s)Assignee: Pav Lucistnik <pav>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description Rene Ladan 2007-01-29 13:50:15 UTC
On amd64 systems, the libraries need to be linked with the -fPIC option, as stated at
http://pointyhat.freebsd.org/errorlogs/amd64-7-latest/libusb-0.1.12_1.log

Add this flag to CFLAGS in the Makefile

Fix: Patch attached with submission follows:
How-To-Repeat: Try to compile the port on an amd64 system.
Comment 1 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-30 18:44:12 UTC
State Changed
From-To: open->feedback

This is incorrect fix. Please re-read the beginning of the email with the log. 


Comment 2 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-30 18:44:12 UTC
Responsible Changed
From-To: freebsd-ports-bugs->pav

Track
Comment 3 Rene Ladan 2007-01-31 10:53:33 UTC
Pav Lucistnik schreef:
> Synopsis: devel/libusb : fix build on amd64
> 
> State-Changed-From-To: open->feedback
> State-Changed-By: pav
> State-Changed-When: Tue Jan 30 18:44:12 UTC 2007
> State-Changed-Why: 
> This is incorrect fix. Please re-read the beginning of the email with the log.
> 
> 
> Responsible-Changed-From-To: freebsd-ports-bugs->pav
> Responsible-Changed-By: pav
> Responsible-Changed-When: Tue Jan 30 18:44:12 UTC 2007
> Responsible-Changed-Why: 
> Track
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=108515
> 
Hmm, the error log has vanished from pointyhat, maybe the problem was
volatile?

-- 
GPG fingerprint = E738 5471 D185 7013 0EE0  4FC8 3C1D 6F83 12E1 84F6
(subkeys.pgp.net)

"It won't fit on the line."
		-- me, 2001
Comment 4 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-31 12:23:38 UTC
> > This is incorrect fix. Please re-read the beginning of the email with the log.

> Hmm, the error log has vanished from pointyhat, maybe the problem was
> volatile?

That build have a fast turn-around. The problem is still present.
The fix goes like this:

diff -a -u -r1.22 Makefile
--- Makefile    3 Dec 2006 11:55:10 -0000       1.22
+++ Makefile    31 Jan 2007 12:23:06 -0000
@@ -32,7 +32,7 @@
 .endif
 
 USE_LDCONFIG=  yes
-GNU_CONFIGURE= yes
+USE_AUTOTOOLS= libtool:15
 
 post-patch:
        @${REINPLACE_CMD} -e 's|{libdir}/pkgconfig|{prefix}/libdata/pkgconfig|g' ${WRKSRC}/configure

What do you think?

-- 
Pav Lucistnik <pav@oook.cz>
              <pav@FreeBSD.org>

As to floating eyes, let them float :).
  - r.g.r.a
Comment 5 Rene Ladan 2007-01-31 13:47:47 UTC
Pav Lucistnik schreef:
>>> This is incorrect fix. Please re-read the beginning of the email with the log.
> 
>> Hmm, the error log has vanished from pointyhat, maybe the problem was
>> volatile?
> 
> That build have a fast turn-around. The problem is still present.
> The fix goes like this:
> 
> diff -a -u -r1.22 Makefile
> --- Makefile    3 Dec 2006 11:55:10 -0000       1.22
> +++ Makefile    31 Jan 2007 12:23:06 -0000
> @@ -32,7 +32,7 @@
>  .endif
>  
>  USE_LDCONFIG=  yes
> -GNU_CONFIGURE= yes
> +USE_AUTOTOOLS= libtool:15
>  
>  post-patch:
>         @${REINPLACE_CMD} -e 's|{libdir}/pkgconfig|{prefix}/libdata/pkgconfig|g' ${WRKSRC}/configure
> 
> What do you think?
> 
On my i386 box, 'port test' now fails because work/.PLIST* assume that
libusb-0.1.so.8.0 and libusbpp-0.1.so.8.0 exist, but libusb*-0.1.so.8
exist instead.

Should I add something like ${MV} libusb*-0.1.so.8 libusb*-0.1.so.8.0 to
the Makefile at pre-install time?

Regards,
Rene
-- 
GPG fingerprint = E738 5471 D185 7013 0EE0  4FC8 3C1D 6F83 12E1 84F6
(subkeys.pgp.net)

"It won't fit on the line."
		-- me, 2001
Comment 6 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-31 13:50:38 UTC
> >>> This is incorrect fix. Please re-read the beginning of the email with the log.
> > 
> >> Hmm, the error log has vanished from pointyhat, maybe the problem was
> >> volatile?
> > 
> > That build have a fast turn-around. The problem is still present.
> > The fix goes like this:
> > 
> > diff -a -u -r1.22 Makefile
> > --- Makefile    3 Dec 2006 11:55:10 -0000       1.22
> > +++ Makefile    31 Jan 2007 12:23:06 -0000
> > @@ -32,7 +32,7 @@
> >  .endif
> >  
> >  USE_LDCONFIG=  yes
> > -GNU_CONFIGURE= yes
> > +USE_AUTOTOOLS= libtool:15
> >  
> >  post-patch:
> >         @${REINPLACE_CMD} -e 's|{libdir}/pkgconfig|{prefix}/libdata/pkgconfig|g' ${WRKSRC}/configure
> > 
> > What do you think?
> > 
> On my i386 box, 'port test' now fails because work/.PLIST* assume that
> libusb-0.1.so.8.0 and libusbpp-0.1.so.8.0 exist, but libusb*-0.1.so.8
> exist instead.
> 
> Should I add something like ${MV} libusb*-0.1.so.8 libusb*-0.1.so.8.0 to
> the Makefile at pre-install time?

No!

It have no business thinking so.8.0 ever existed. If this happens on
your machine, obviously my patch is wrong and I haven't done proper
testing of it.

Can you try adding this to the port:
	@${REINPLACE_CMD} -e 's|echo aout|echo elf|g' ${WRKSRC}/configure

and see if it helps?

-- 
Pav Lucistnik <pav@oook.cz>
              <pav@FreeBSD.org>

94 outdated ports on the box,
94 outdated ports.
Portupgrade one, an hour 'til done,
82 outdated ports on the box.
Comment 7 Rene Ladan 2007-01-31 14:07:41 UTC
Pav Lucistnik schreef:
>>>>> This is incorrect fix. Please re-read the beginning of the email with the log.
>>>> Hmm, the error log has vanished from pointyhat, maybe the problem was
>>>> volatile?
>>> That build have a fast turn-around. The problem is still present.
>>> The fix goes like this:
>>>
>>> diff -a -u -r1.22 Makefile
>>> --- Makefile    3 Dec 2006 11:55:10 -0000       1.22
>>> +++ Makefile    31 Jan 2007 12:23:06 -0000
>>> @@ -32,7 +32,7 @@
>>>  .endif
>>>  
>>>  USE_LDCONFIG=  yes
>>> -GNU_CONFIGURE= yes
>>> +USE_AUTOTOOLS= libtool:15
>>>  
>>>  post-patch:
>>>         @${REINPLACE_CMD} -e 's|{libdir}/pkgconfig|{prefix}/libdata/pkgconfig|g' ${WRKSRC}/configure
>>>
>>> What do you think?
>>>
>> On my i386 box, 'port test' now fails because work/.PLIST* assume that
>> libusb-0.1.so.8.0 and libusbpp-0.1.so.8.0 exist, but libusb*-0.1.so.8
>> exist instead.
>>
>> Should I add something like ${MV} libusb*-0.1.so.8 libusb*-0.1.so.8.0 to
>> the Makefile at pre-install time?
> 
> No!
>
Nevermind, I figured from the cvs-ports archive that I have a stale
bsd.port.mk installed (from the modular xorg tree), which has a sed
command to mangle library names.

If I manually update to revision 1.546 of bsd.port.mk, 'port test'
succeeds using the USE_AUTOTOOLS line.

[...]

Regards,
Rene
-- 
GPG fingerprint = E738 5471 D185 7013 0EE0  4FC8 3C1D 6F83 12E1 84F6
(subkeys.pgp.net)

"It won't fit on the line."
		-- me, 2001
Comment 8 Pav Lucistnik freebsd_committer freebsd_triage 2007-01-31 14:14:43 UTC
State Changed
From-To: feedback->closed

Used the libtool approach in the end
Comment 9 dfilter service freebsd_committer freebsd_triage 2007-01-31 14:15:12 UTC
pav         2007-01-31 14:14:55 UTC

  FreeBSD ports repository

  Modified files:
    devel/libusb         Makefile 
  Log:
  - Fix objformat fallout by deploying system libtool
  
  PR:             ports/108515
  
  Revision  Changes    Path
  1.23      +1 -1      ports/devel/libusb/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"