On Thu, Jun 23, 2016 at 09:03:43AM +0100, Stuart Henderson wrote: > On 2016/06/23 00:25, Ted Unangst wrote: > > Stuart Henderson wrote: > > > Turns out I forgot about the pthread stubs, without which there > > > are build failures in mandoc and various ports things unless we link > > > them with -lpthread. This broke a few things in my first ports test > > > build, but thanks to guenther's work it should now be valid to pull > > > this in via an inter-library dependency rather than having to > > > sprinkle it over mandoc and lots of the ports tree. > > > > > > > Index: Makefile > > > -# so that it works with NO THREADS > > > -SRCS += pthread_stub.c > > > - > > > -# mem3.c mem5.c > > > +SRCS = sqlite3.c > > > +LDADD = -lpthread > > > > Why are we dropping the stubs in favor of linking with libpthread? > > Trying to avoid too many changes to upstream's source. But I suppose > we can keep that as a separate file - just tested that with 3 things > where I ran into the problem (mandoc, www/kcaldav, www/nsh,static) > and they're happy. And I've tried build usr.bin/sqlite3 both with > and without -pthread and both versions of that also work OK for the > things I've tested. > > So, new diff: https://junkpile.org/sqlite-3.11.0.diff.gz,2 > > pthread_stub.c moves from lib/libsqlite3/tsrc/ to lib/libsqlite3/ > but is otherwise unchanged from the in-tree version. > > The only change to the Makefile from my previous diff is adding > pthread_stub.c to SRCS. >
Like I've stated before, I think this is the best way to move forward for the time being, so you have my ok. -- James Turner