From owner-freebsd-questions@freebsd.org Sun Dec 8 08:22:58 2019 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DD9941DCCFE for ; Sun, 8 Dec 2019 08:22:58 +0000 (UTC) (envelope-from freebsd-lists-5@thismonkey.com) Received: from mail-01.thismonkey.com (mail-01.thismonkey.com [IPv6:2406:3400:35e:6602::a01:232]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thismonkey.com", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 47Vzpl6zJHz3JjB for ; Sun, 8 Dec 2019 08:22:55 +0000 (UTC) (envelope-from freebsd-lists-5@thismonkey.com) X-TM-Via-MX: mail-01.thismonkey.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=thismonkey.com; s=dkim; t=1575793360; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=v10AOWl2L4uIlmEFhAZHN8lb3oFCKikBhocXwLMGYuE=; b=Kiph4vXtjnJ+CQiKCc5z5oGyIqoTRhNYBJIIufdq2QvQ5bI0p/TJ1YWK+PW12NzN9LVRVa L7EI3rbSpOVv4BBCssDk5eQn4YUvMUOCknHggcebKaKJ7e0b+LWaEGFoNAZOH3p31g9iqx GYrKooZ3SISXPnqDu+uaUPTSluRjCdE= Received: from utility-01.thismonkey.com (utility-01.thismonkey.com [IPv6:2406:3400:35e:6601:0:0:a01:120]) by mail-01.thismonkey.com (8.15.2/8.15.2) with ESMTPS id xB88Mcq0065550 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Sun, 8 Dec 2019 19:22:40 +1100 (EST) (envelope-from freebsd-lists-5@thismonkey.com) Received: from utility-01.thismonkey.com (localhost [127.0.0.1]) by utility-01.thismonkey.com (8.15.2/8.15.2) with ESMTP id xB88McF5093405 for ; Sun, 8 Dec 2019 19:22:38 +1100 (EST) (envelope-from freebsd-lists-5@thismonkey.com) Received: (from root@localhost) by utility-01.thismonkey.com (8.15.2/8.15.2/Submit) id xB88MbRL093404 for freebsd-questions@freebsd.org; Sun, 8 Dec 2019 19:22:37 +1100 (EST) (envelope-from freebsd-lists-5@thismonkey.com) Date: Sun, 8 Dec 2019 19:22:37 +1100 From: Scott Aitken To: freebsd-questions@freebsd.org Subject: Re: Cross-compiling with go for arm on amd64. Possible? Message-ID: <20191208082237.GA80246@thismonkey.com> Mail-Followup-To: freebsd-questions@freebsd.org References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.11.4 (2019-03-13) X-Virus-Scanned: clamav-milter 0.101.4 at mail-01.thismonkey.com X-Virus-Status: Clean X-Greylist: inspected by milter-greylist-4.6.2 (mail-01.thismonkey.com [IPv6:2406:3400:35e:6602:0:0:a01:232]); Sun, 08 Dec 2019 19:22:41 +1100 (EST) for IP:'2406:3400:35e:6601::a01:120' DOMAIN:'utility-01.thismonkey.com' HELO:'utility-01.thismonkey.com' FROM:'freebsd-lists-5@thismonkey.com' RCPT:'' SPF:' X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (mail-01.thismonkey.com [IPv6:2406:3400:35e:6602:0:0:a01:232]); Sun, 08 Dec 2019 19:22:41 +1100 (EST) X-Rspamd-Queue-Id: 47Vzpl6zJHz3JjB X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none (invalid DKIM record) header.d=thismonkey.com header.s=dkim header.b=Kiph4vXt; dmarc=pass (policy=none) header.from=thismonkey.com; spf=pass (mx1.freebsd.org: domain of freebsd-lists-5@thismonkey.com designates 2406:3400:35e:6602::a01:232 as permitted sender) smtp.mailfrom=freebsd-lists-5@thismonkey.com X-Spamd-Result: default: False [-0.98 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.93)[-0.925,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.86)[-0.865,0]; RCVD_COUNT_THREE(0.00)[3]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[thismonkey.com:~]; DMARC_POLICY_ALLOW(-0.50)[thismonkey.com,none]; R_DKIM_PERMFAIL(0.00)[thismonkey.com:s=dkim]; IP_SCORE(0.61)[asn: 10143(3.04), country: AU(0.01)]; FROM_EQ_ENVFROM(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:10143, ipnet:2406:3400:300::/40, country:AU]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 08 Dec 2019 08:22:58 -0000 > Scott Aitken writes: > > > Hi, > > > > So I wanted to install dns/dnscrypt-proxy2 on my Raspberry Pi running FreeBSD > > 12.0-RELEASE r341666 GENERIC arm. > > > > There's no package version, so I tried compiling. Unfortunately that didn't > > work as the Go dependency ran out of RAM compiling. And there's no package > > for Go... > > > > So I fired up a VM and installed ports-mgmt/poudriere. Set it all up and > > added dns/dnscrypt-proxy2 to my shopping list... > > > > Unfortunately it skipped lang/go: > > > > Code: > > [00:01:14] [01] [00:00:00] Building lang/go | go-1.13.4,1 > > [00:01:16] [01] [00:00:02] Finished lang/go | go-1.13.4,1: Ignored: fails to > > build with qemu-user-static > > [00:01:16] [01] [00:00:02] Skipping dns/dnscrypt-proxy2 | > > dnscrypt-proxy2-2.0.31_1: Dependent port lang/go | go-1.13.4,1 ignored > > > > Apparently Go 1.3 won't compile under the emulator (see PR 221297 for some > > background. > > > > Is it possible for go to cross-compile for arm on amd64? > > I don't know about cross-compiling, but I have built go from source on a > Raspberry Pi 2. In my case I was running 12.1-RELEASE, and I built > go-1.13.1,1 about 2 weeks ago. My typescript file doesn't show any > errors, and time showed a 28 minute build time and another 15 minutes to > create a binary package. That was after installing the go14 binary > package. > > -- > Carl Johnson carlj@peak.org > Hi Carl, I had no luck as I said. I killed every daemon I could and simply saw the memory in top approach zero after about 3 minutes into the build, and then the core dump. Other than OS and compiler options (of which I'm using the default) I can't think of why you had success whereas I didn't. This is my dmesg - are you using the same platform? FreeBSD 12.0-RELEASE r341666 GENERIC arm FreeBSD clang version 6.0.1 (tags/RELEASE_601/final 335540) (based on LLVM 6.0.1) VT: init without driver. CPU: ARM Cortex-A7 r0p5 (ECO: 0x00000000) CPU Features: Multiprocessing, Thumb2, Security, Virtualization, Generic Timer, VMSAv7, PXN, LPAE, Coherent Walk Optional instructions: SDIV/UDIV, UMULL, SMULL, SIMD(ext) LoUU:2 LoC:3 LoUIS:2 Cache level 1: 32KB/64B 4-way data cache WB Read-Alloc Write-Alloc 32KB/32B 2-way instruction cache Read-Alloc Cache level 2: 512KB/64B 8-way unified cache WB Read-Alloc Write-Alloc real memory = 0 (0 MB) avail memory = 957149184 (912 MB) No PSCI/SMCCC call function found FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs Thanks, Scott