Ping :) On Sun, 13 Oct 2019 01:23:58 +0200 Charlene Wendling wrote:
> Hi, > > > http://build-failures.rhaalovely.net/sparc64/2019-10-06/devel/py-unicorn%2Cpython3.log > > http://build-failures.rhaalovely.net/powerpc/2019-09-17/devel/py-unicorn.log > > It seems it is happening since the python3 flavor has been enabled. > > '-Bsymbolic-functions' is not supported by our ld.bfd, so i've simply > split linking options according to which linker is used. I could have > totally removed that option, but i heard it allows better > performances. > > This builds fine on macppc [0] and amd64. > > Comments/feedback are welcome, > > Charlène. > > > [0] https://bin.charlenew.xyz/py-unicorn.tgz > > > Index: Makefile > =================================================================== > RCS file: /cvs/ports/devel/py-unicorn/Makefile,v > retrieving revision 1.6 > diff -u -p -u -p -r1.6 Makefile > --- Makefile 12 Jul 2019 20:45:55 -0000 1.6 > +++ Makefile 12 Oct 2019 23:17:27 -0000 > @@ -5,7 +5,7 @@ COMMENT = Unicorn CPU emulator engine > MODPY_EGG_VERSION = 1.0.1 > DISTNAME = unicorn-${MODPY_EGG_VERSION} > PKGNAME = py-${DISTNAME} > -REVISION = 1 > +REVISION = 2 > > CATEGORIES = devel > > @@ -32,6 +32,14 @@ BUILD_DEPENDS = lang/python/$ > {MODPY_DEF USE_GMAKE = Yes > > MAKE_ENV += V=1 > + > +# our ld.bfd has no '-Bsymbolic-functions' option support > +.include <bsd.port.arch.mk> > +.if ${PROPERTIES:Mlld} > +MAKE_ENV += LD_IS_LLD=1 > +.else > +MAKE_ENV += LD_IS_LLD=0 > +.endif > > pre-configure: > ${SUBST_CMD} ${WRKSRC}/src/Makefile > Index: patches/patch-src_Makefile > =================================================================== > RCS file: /cvs/ports/devel/py-unicorn/patches/patch-src_Makefile,v > retrieving revision 1.2 > diff -u -p -u -p -r1.2 patch-src_Makefile > --- patches/patch-src_Makefile 1 Jun 2019 20:00:01 > -0000 1.2 +++ patches/patch-src_Makefile 12 Oct 2019 > 23:17:27 -0000 @@ -1,11 +1,25 @@ > $OpenBSD: patch-src_Makefile,v 1.2 2019/06/01 20:00:01 kn Exp $ > > -ERROR: Cannot use '/usr/local/bin/python3.6', Python 2.4 or later is > required. +Hunk#1: -Bsymbolic-functions is not supported by ld.bfd > +Hunk#2: Fix error: Cannot use '/usr/local/bin/python3.6', Python 2.4 > or > + later is required. > > Index: src/Makefile > --- src/Makefile.orig > +++ src/Makefile > -@@ -212,7 +212,7 @@ all: unicorn > +@@ -141,7 +141,11 @@ else > + EXT = so > + VERSION_EXT = $(EXT).$(API_MAJOR) > + AR_EXT = a > ++ifeq ($(LD_IS_LLD),1) > + $(LIBNAME)_LDFLAGS += -Wl,-Bsymbolic-functions,-soname,lib$ > (LIBNAME).$(VERSION_EXT) ++else > ++$(LIBNAME)_LDFLAGS += -Wl,-soname,lib$(LIBNAME).$(VERSION_EXT) > ++endif > + UNICORN_CFLAGS += -fvisibility=hidden > + endif > + > +@@ -212,7 +216,7 @@ all: unicorn > > qemu/config-host.h-timestamp: > cd qemu && \ >