On Sun, 21 Apr 2019 21:52:59 -0400 Kurt Mosiejczuk <k...@cranky.work> wrote:
> On Sun, Apr 21, 2019 at 08:50:49PM -0400, Kurt Mosiejczuk wrote: > > > > I've fixes for two of them, i don't have an arm64 box to test > > > them, but ports-gcc-8 on macppc emits the same errors. > > > I got freeimage to build on my arm64 box. It's "make test" > > explicitly calls "g++' so that didn't work. But, it built with your > > patch. Thanks! We need to remove that hardcoded g++ indeed. I had to pass MAKE_ENV explicitly to the custom test target, and to dos2unix the test Makefile like the toplevel one to have clean diffs. I'm attaching the new diff. The test build works on amd64 and macppc. > > libnipper I'm still working on building. It was builing dependencies > > and is hung up on my zstd lib being 3.0 while it wants 2.0. I'm > > still banging on it. > > OK. After rebuilding libarchive I was able to build security/libnipper > on my arm64 box. > --Kurt > Index: Makefile =================================================================== RCS file: /cvs/ports/graphics/freeimage/Makefile,v retrieving revision 1.13 diff -u -p -u -p -r1.13 Makefile --- Makefile 19 Nov 2018 18:46:16 -0000 1.13 +++ Makefile 22 Apr 2019 09:01:04 -0000 @@ -4,7 +4,7 @@ COMMENT= c++ library for common image f DISTNAME= FreeImage3152 PKGNAME= freeimage-3.15.2 -REVISION = 6 +REVISION= 7 CATEGORIES= graphics SHARED_LIBS+= freeimage 2.0 @@ -31,9 +31,10 @@ MAKE_ENV= LIBfreeimage_VERSION=${LIBfre MAKE_TARGET= Makefile.gnu post-extract: - perl -pi -e 's/\015//g' ${WRKSRC}/Makefile.gnu + perl -pi -e 's/\015//g' ${WRKSRC}/Makefile.gnu \ + ${WRKSRC}/TestAPI/Makefile do-test: - cd ${WRKSRC}/TestAPI && ${MAKE_PROGRAM} + cd ${WRKSRC}/TestAPI && ${MAKE_PROGRAM} ${MAKE_ENV} .include <bsd.port.mk> Index: patches/patch-Source_LibRawLite_internal_dcraw_common_cpp =================================================================== RCS file: /cvs/ports/graphics/freeimage/patches/patch-Source_LibRawLite_internal_dcraw_common_cpp,v retrieving revision 1.1 diff -u -p -u -p -r1.1 patch-Source_LibRawLite_internal_dcraw_common_cpp --- patches/patch-Source_LibRawLite_internal_dcraw_common_cpp 7 Apr 2018 09:07:59 -0000 1.1 +++ patches/patch-Source_LibRawLite_internal_dcraw_common_cpp 22 Apr 2019 09:01:04 -0000 @@ -1,10 +1,21 @@ $OpenBSD: patch-Source_LibRawLite_internal_dcraw_common_cpp,v 1.1 2018/04/07 09:07:59 rsadowski Exp $ -fix clang 6.0 build +Hunk #1: fix the build when char is unsigned by default (ppc, arm) + +fix clang>=6 build Index: Source/LibRawLite/internal/dcraw_common.cpp --- Source/LibRawLite/internal/dcraw_common.cpp.orig +++ Source/LibRawLite/internal/dcraw_common.cpp +@@ -2368,7 +2368,7 @@ void CLASS quicktake_100_load_raw() + + void CLASS kodak_radc_load_raw() + { +- static const char src[] = { ++ static const signed char src[] = { + 1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8, + 1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8, + 2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8, @@ -3917,7 +3917,7 @@ void CLASS lin_interpolate() */ void CLASS vng_interpolate() Index: patches/patch-TestAPI_Makefile =================================================================== RCS file: patches/patch-TestAPI_Makefile diff -N patches/patch-TestAPI_Makefile --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-TestAPI_Makefile 22 Apr 2019 09:01:04 -0000 @@ -0,0 +1,14 @@ +$OpenBSD$ + +Index: TestAPI/Makefile +--- TestAPI/Makefile.orig ++++ TestAPI/Makefile +@@ -2,7 +2,7 @@ + default: all + + all: +- g++ -I../Dist/ *.cpp ../Dist/libfreeimage.a -o testAPI ++ $(CXX) -I../Dist/ *.cpp ../Dist/libfreeimage.a -o testAPI + + clean: + rm -f *.o testAPI *.png *.tif