X-Original-To: alpine-devel@lists.alpinelinux.org Received: from sender163-mail.zoho.com (sender163-mail.zoho.com [74.201.84.163]) by lists.alpinelinux.org (Postfix) with ESMTP id 8EA4E5C41B0 for ; Sun, 22 Jan 2017 23:47:03 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1485128806; s=default; d=flatglobe.org; i=tmhoang@flatglobe.org; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References:MIME-Version:Content-Type:Content-Transfer-Encoding; l=4090; bh=62pf6M8GU6mh7W8uDois+wVe3bK8pgSB470ciR9H2hE=; b=HlH291EtYM3UZU/P+WLavQ2pWVxxKqg4/1M+M0ZMDMnSP/en4amFtIGHT1oXEzYx 9si+mY5Xwx6XNKBJ2StlrTHtWonsntBZULsbZS6e0tSrDL+KiZC88Tmm2jY+K3xLKl4 QoItcOCFtBpLNYoOlYVTNP5jw3U5i/Uba77cb0Tw= Received: from emily (cpe-204-210-151-44.hvc.res.rr.com [204.210.151.44]) by mx.zohomail.com with SMTPS id 14851288069301005.8204618879798; Sun, 22 Jan 2017 15:46:46 -0800 (PST) Date: Sun, 22 Jan 2017 18:46:52 -0500 From: "Tuan M. Hoang" To: Timo Teras Cc: "alpine-devel" Subject: Re: [alpine-devel] Porting Alpine scripts Message-ID: <20170122184652.338e4344.tmhoang@flatglobe.org> In-Reply-To: <20161121105925.685761a2@vostro.util.wtbts.net> References: <155a8e57d76.f37920c130996.6728092923369604578@flatglobe.org> <155e6497a8e.11ad265cf269464.7355344611305011615@flatglobe.org> <155f440c618.129c9f0aa5155.5728200182511575692@flatglobe.org> <20160718084038.23773fca@vostro.util.wtbts.net> <1560fbd5a78.dbf5aa7b48820.4632348656468847927@flatglobe.org> <20160722084514.7c01123f@vostro.util.wtbts.net> <15614c77014.1200f0e697958.371787825394349914@flatglobe.org> <20160723092945.0680e7fd@vostro> <1562340dbde.12a594a5120275.3795912911296475631@flatglobe.org> <156260c81a5.f458ee7355285.6767768145040849925@flatglobe.org> <20160726194654.69b12731@vostro> <15635238f98.e963f442298215.3433654478481171006@flatglobe.org> <20161116023639.23b44cf1.tmhoang@flatglobe.org> <20161117082440.7f5e0fa0@vostro.util.wtbts.net> <20161119041548.765e6513.tmhoang@flatglobe.org> <20161119092109.13567a93@vostro> <20161121073927.2d0a9e65.tmhoang@flatglobe.org> <20161121105925.685761a2@vostro.util.wtbts.net> Organization: flatglobe.org X-Mailinglist: alpine-devel Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Mon, 21 Nov 2016 10:59:25 +0200 Timo Teras wrote: > I'm still looking at the rest of the patches. Here's my review > thoughts of them: >=20 >=20 > - aports/linux-vanilla looks good. Though you probably just got the > kernel config from some other linux distro? It would probably be > good to cross-check that with other Alpine's linux-vanilla configs to > see that it is more or less in harmony. I have done some work on it. You can find for reference here : http://flatglobe.org/config-vanilla.s390x > - aports/musl looks mostly ok. We hope musl would soon make release, > and much of the patch is not needed then as it's mostly upstreamed > now. There's one issue that's causing some of your trouble. The > following hunk is wrong: >=20 > @@ -142,6 +146,7 @@ compat() { > mips*) _ld=3D"ld.so.1" ;; > + s390*) _ld=3D"ld-musl-s390x.so.1" ;; >=20 > The compat package is supposed to create symlinks that mimic glibc > provided ld and libraries. The _ld var needs to be setup to be the > glibc ld name, not the musl one. Looking at gcc, the proper thing > here to do is: > - mips*) _ld=3D"ld.so.1" ;; > + mips* | s390*) _ld=3D"ld.so.1" ;; >=20 Thanks. This helped a lot. > - In main/libressl you add --disable-asm? Why is this needed? > It seemed to compile just fine without this flag. If really needed, > this should be made conditional so that it's only applied for s390. >=20 Yep this is old flag. Now it is obsolete. Btw, fyi, 31 support of s390 architecture has been dropped, now it's all s390x (64 bit version of s390) for all packages, except in linux kernel, the name still remains s390. https://github.com/dbussink/linux/commit/5a79859ae0f35d25c67a03e82bf0c80592= f16a39 I am currently having two issues, hope you can take some time to see it. 1. I was running Alpine s390x in Docker with some essential cross-compiled packages targeting s390x, in order to compile natively the toolchains. It all boils down to missing perl package as compile-time dependency. Perl cannot be cross-compiled, yet is needed for native compile. When I try to compile perl natively (inside either Docker or a chroot), I had segmentation fault on running fakeroot. Just wonder if this is the correct way you did and segmentation fault is only my thing. 2. I was having an error when building linux-vanilla-dev ( with above kernel config ). When running $ make in dev() in APKBUILD, HOSTCC compiles some scripts in "$srcdir"/linux-$_kernver/scripts directory into host arch (x86_64) object/exec files. These files were later get copied into "$subpkgdir"/usr/src/linux-headers-${_abi_release} (aports/main/linux-vanilla/pkg/linux-vanilla-dev/usr/src/linux-headers-4.4.= 34). Then libc.musl-x86_64.so.1 comes up in as a needed .so file in later steps (scan_shared_objects() function). This happens for linux-vanilla-dev package, while bootstraping both aarch64, and s390x using aports master. $ scanelf --nobanner --recursive --needed aports/main/linux-vanilla/pkg/linux-vanilla-dev ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/sortextable ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/asn1_compiler ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/dtc/dtc ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/recordmcount ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/genksyms/genks= yms ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/kconfig/conf ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/mod/modpost ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/mod/mk_elfconf= ig ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/basic/bin2c ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/basic/fixdep ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/conmakehash ET_DYN libc.musl-x86_64.so.1 ./usr/src/linux-headers-4.4.38/scripts/kallsyms Thanks, Tuan --- Unsubscribe: alpine-devel+unsubscribe@lists.alpinelinux.org Help: alpine-devel+help@lists.alpinelinux.org ---