Bug#773341: [Pkg-javascript-devel] Bug#773341: libuv: link against -pthread to fix underlinking issues

2014-12-18 Thread Logan Rosen
Hi Luca,

It has been committed upstream:
https://github.com/libuv/libuv/commit/ccd9745a681f625a8fc41f27da086ba42eac5691

Thanks,
Logan


Bug#773341: [Pkg-javascript-devel] Bug#773341: libuv: link against -pthread to fix underlinking issues

2014-12-17 Thread Luca Bruno
On Wednesday 17 December 2014 02:54:05 Logan Rosen wrote:

 Although this isn't causing an FTBFS in Debian, as we use different linker
 flags, it is probably a good idea to apply this fix here as well in case
 Debian switches to ld --as-needed in the future.

Thanks a lot for your report and your patch.
As it is directly touching original Makefile and as upstream is usually quite 
fast in reviewing/merging patches, can you please submit it directly as a PR
against the v0.10 branch there? https://github.com/libuv/libuv

Cheers, Luca

-- 
 .''`.  ** Debian GNU/Linux **  | Luca Bruno (kaeso)
: :'  :   The Universal O.S.| lucab (AT) debian.org
`. `'`  | GPG Key ID: 0x4F3BBEBF
  `- http://www.debian.org  | Debian GNU/Linux Developer


signature.asc
Description: This is a digitally signed message part.


Bug#773341: libuv: link against -pthread to fix underlinking issues

2014-12-16 Thread Logan Rosen
Package: libuv
Version: 0.10.28-5
Severity: normal
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu vivid ubuntu-patch

Dear Maintainer,

As you can see from the build logs for libuv (for example on amd64) [1], there 
are warnings from dpkg-shlibdeps such as the following:

dpkg-shlibdeps: warning: symbol pthread_rwlock_rdlock used by 
debian/libuv0.10/usr/lib/x86_64-linux-gnu/libuv.so.0.10 found in none of the 
libraries

This caused residual effects in Ubuntu, where getdns (a package that 
build-depends on libuv0.10-dev) failed to build due to undefined references to 
pthread symbols in the libuv.so.

Although this isn't causing an FTBFS in Debian, as we use different linker 
flags, it is probably a good idea to apply this fix here as well in case Debian 
switches to ld --as-needed in the future.

In Ubuntu, the attached patch was applied to achieve the following:

  * Link against -pthread to fix issue with ld --as-needed.

Thanks for considering the patch.

Logan Rosen

[1] 
https://buildd.debian.org/status/fetch.php?pkg=libuvarch=amd64ver=0.10.28-5stamp=1411308090

-- System Information:
Debian Release: jessie/sid
  APT prefers vivid-updates
  APT policy: (500, 'vivid-updates'), (500, 'vivid-security'), (500, 'vivid'), 
(100, 'vivid-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.16.0-28-generic (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: upstart (via init_is_upstart())
diff -Nru libuv-0.10.28/debian/patches/link-pthread.diff libuv-0.10.28/debian/patches/link-pthread.diff
--- libuv-0.10.28/debian/patches/link-pthread.diff	1969-12-31 19:00:00.0 -0500
+++ libuv-0.10.28/debian/patches/link-pthread.diff	2014-12-14 04:11:33.0 -0500
@@ -0,0 +1,11 @@
+--- a/config-unix.mk
 b/config-unix.mk
+@@ -22,7 +22,7 @@
+ CSTDFLAG=--std=c89 -pedantic -Wall -Wextra -Wno-unused-parameter
+ CFLAGS += -g
+ CPPFLAGS += -I$(SRCDIR)/src
+-LDFLAGS=-lm
++LDFLAGS=-lm -pthread
+ 
+ CPPFLAGS += -D_LARGEFILE_SOURCE
+ CPPFLAGS += -D_FILE_OFFSET_BITS=64
diff -Nru libuv-0.10.28/debian/patches/series libuv-0.10.28/debian/patches/series
--- libuv-0.10.28/debian/patches/series	2014-09-20 17:24:57.0 -0400
+++ libuv-0.10.28/debian/patches/series	2014-12-14 04:10:55.0 -0500
@@ -2,3 +2,4 @@
 make-clean.diff
 test_runner.diff
 arm64-epoll-ftbfs.diff
+link-pthread.diff