From d4a970f27322e6a060ef30851116e16f27f55202 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Mon, 03 Aug 2020 02:10:12 -0400 Subject: build: Fix install_dbg target `[ x"$(variant)" != x'dbg' ] && oh-strip -d $(destdir)` returned non-zero (from the `[` command), so an if construct is better. oh-installfiles complained about leftover files, so remove all the development files. --- (limited to 'build') diff --git a/build b/build index 8441f6b..5bfac03 100755 --- a/build +++ b/build @@ -29,6 +29,8 @@ build_client_cflags = $(common_cflags) \ build_full_cflags = $(common_cflags) build_dbg_cflags = $(common_cflags) +arch = $(OPK_HOST_ARCH) + nop: @: @@ -55,17 +57,27 @@ build: build_client build_full build_dbg install_client install_full install_dbg: build oh-autoinstall -B $(builddir) -d $(destdir) rm -Rf \ - $(destdir)/usr/lib/$(OPK_HOST_ARCH)/libwolfssl.la \ + $(destdir)/usr/lib/$(arch)/libwolfssl.la \ $(destdir)/usr/share/doc/wolfssl/example/ \ $(destdir)/usr/share/doc/wolfssl/README.txt \ $(destdir)/usr/share/doc/wolfssl/taoCert.txt oh-fixperms -d $(destdir) - [ x"$(variant)" != x'dbg' ] && oh-strip -d $(destdir) - OPK_PACKAGES="libwolfssl.$(abi_ver)-$(variant)" \ - oh-installfiles -d $(destdir) - [ x"$(variant)" != x'dbg' ] && \ - OPK_PACKAGES="libwolfssl.$(abi_ver)-$(variant)-dev" \ - oh-installfiles -d $(destdir) + set -e; if [ x"$(variant)" != x'dbg' ]; then \ + oh-strip -d $(destdir); \ + OPK_PACKAGES="\ + libwolfssl.$(abi_ver)-$(variant) \ + libwolfssl.$(abi_ver)-$(variant)-dev \ + " oh-installfiles -d $(destdir); \ + else \ + rm -Rf \ + $(destdir)/usr/include/ \ + $(destdir)/usr/lib/$(arch)/libwolfssl.so \ + $(destdir)/usr/lib/$(arch)/pkgconfig/wolfssl.pc \ + $(destdir)/usr/bin/wolfssl-config; \ + OPK_PACKAGES="\ + libwolfssl.$(abi_ver)-$(variant) \ + " oh-installfiles -d $(destdir); \ + fi install: install_client install_full install_dbg oh-shlibdeps -- cgit v0.9.1