From owner-freebsd-questions@freebsd.org Mon Nov 27 19:59:47 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 043ABDE6375 for ; Mon, 27 Nov 2017 19:59:47 +0000 (UTC) (envelope-from tijl@freebsd.org) Received: from mailrelay119.isp.belgacom.be (mailrelay119.isp.belgacom.be [195.238.20.146]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "relay.skynet.be", Issuer "GlobalSign Organization Validation CA - SHA256 - G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 57AA128EF for ; Mon, 27 Nov 2017 19:59:45 +0000 (UTC) (envelope-from tijl@freebsd.org) X-Belgacom-Dynamic: yes IronPort-PHdr: =?us-ascii?q?9a23=3AYEOhEhQdd7KBs/UfTJhj0fLWqtpsv+yvbD5Q0YIu?= =?us-ascii?q?jvd0So/mwa6yZBON2/xhgRfzUJnB7Loc0qyN4vCmATRIyK3CmUhKSIZLWR4BhJ?= =?us-ascii?q?detC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TW94jEIBxrwKxd+?= =?us-ascii?q?KPjrFY7OlcS30P2594HObwlSijewZbB/IA+qoQnNq8IbnZZsJqEtxxXTv3BGYf?= =?us-ascii?q?5WxWRmJVKSmxbz+MK994N9/ipTpvws6ddOXb31cKokQ7NYCi8mM30u683wqRbD?= =?us-ascii?q?VwqP6WACXWgQjxFFHhLK7BD+Xpf2ryv6qu9w0zSUMMHqUbw5Xymp4qF2QxHqlS?= =?us-ascii?q?gHLSY0/m/XhMJukaxVoxCupxJwzIHIb4+YL+Z+c6HBcd8GWWZNQthdWipcCY28?= =?us-ascii?q?dYsPCO8BMP5GoYn8pVsOqQa1CBerBOPo0T9HmHr20rc80+Q6DArL2xAgH9MMsH?= =?us-ascii?q?TQt9j7NL0SXv6rw6TV0DvNYela2TDn6IjHax0sp+yHU7x3ccrU00YvFgXFg02e?= =?us-ascii?q?qYz/ITyayP8Cs3OG4OZ6UuKvkWEnpxltrTexwMcslo7JhpkPxlDD7yV5z4A4Ls?= =?us-ascii?q?C7Rk5jedOpE4ZcuzuEO4Z5Qs4uWXxktSQ+x7EcuJO2fi4Hw4k9yRHFcfyIaY2I?= =?us-ascii?q?7wrmVOaWPDh3mmpoeKm6hxau6UigzfD8VtWs3FZKsCVFlt7Mu2gO1xPJ7siHS/?= =?us-ascii?q?598Vm72TaIzQzT9uBEIUIwlabBN5EhxbkwloENvkTGBCD2nl72gLWRdkU+9eik?= =?us-ascii?q?8+XnYrP4qZ+AL4J5iRzyPr4wlsGwAek0KBUCUmqf9Oim1bDu/1X1QLBQgf03lq?= =?us-ascii?q?nZvoraJcMepqOhHw9V04Qj6xKkAjeoytQXg2cII0leeB2alYTpPEvOIP/gAfel?= =?us-ascii?q?n1usiCtrx+zBPrD5DJXNNGbMn6n6crZm9kFQ0RMzzc1B6JJPFrEBIfXzWknqtN?= =?us-ascii?q?HDAB85KRK7zPj8B9Vmy4wSQ2WPArWWMPCajVjdrNkuIeyBYsc3/n7YNvwp6uSk?= =?us-ascii?q?xSs4mncGf6y02Zcacja+GqI1DV+eZC/Qg9UFWUwNuREzSeXskxXWTT9RY16cRa?= =?us-ascii?q?8xzAoXToW8AtGQFciWnLWd0XLjTdVtbWdcBwXUHA=3D=3D?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A2AlCgArbRxa/0Oz9VFdGgEBAQEBAgEBA?= =?us-ascii?q?QEIAQEBAYM8VhBuJwGPEo4CHQEBgXw0AYcMkT0thAOBFQKEc0QUAQEBAQEBAQE?= =?us-ascii?q?BAWoogjgigkYBBTocIxALGAklDyoeBhOKJgylRBGDTYp6AQEBAQEBBAEBAQEBI?= =?us-ascii?q?4M6iHCLFAWiRodyjQ2BAIIFkFaMdop+NiKBUEwwCIJiCYJJHIFoQDYBiioBAQE?= X-IPAS-Result: =?us-ascii?q?A2AlCgArbRxa/0Oz9VFdGgEBAQEBAgEBAQEIAQEBAYM8VhB?= =?us-ascii?q?uJwGPEo4CHQEBgXw0AYcMkT0thAOBFQKEc0QUAQEBAQEBAQEBAWoogjgigkYBB?= =?us-ascii?q?TocIxALGAklDyoeBhOKJgylRBGDTYp6AQEBAQEBBAEBAQEBI4M6iHCLFAWiRod?= =?us-ascii?q?yjQ2BAIIFkFaMdop+NiKBUEwwCIJiCYJJHIFoQDYBiioBAQE?= Received: from 67.179-245-81.adsl-dyn.isp.belgacom.be (HELO kalimero.tijl.coosemans.org) ([81.245.179.67]) by relay.skynet.be with ESMTP; 27 Nov 2017 20:58:32 +0100 Received: from kalimero.tijl.coosemans.org (kalimero.tijl.coosemans.org [127.0.0.1]) by kalimero.tijl.coosemans.org (8.15.2/8.15.2) with ESMTP id vARJwVln014428; Mon, 27 Nov 2017 20:58:32 +0100 (CET) (envelope-from tijl@FreeBSD.org) Date: Mon, 27 Nov 2017 20:58:31 +0100 From: Tijl Coosemans To: "Sijmen J. Mulder" Cc: freebsd-questions@freebsd.org Subject: Re: Best way to set up a build environment in /compat/linux Message-ID: <20171127205831.730be29d@kalimero.tijl.coosemans.org> In-Reply-To: <1a02e783-b99e-fbc5-3809-91b452ab699d@sjmulder.nl> References: <1a02e783-b99e-fbc5-3809-91b452ab699d@sjmulder.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Nov 2017 19:59:47 -0000 On Tue, 21 Nov 2017 12:49:25 +0100 "Sijmen J. Mulder" wrote: > With Linux emulation enabled I can successfully run a statically linked > Linux binary that I built on an Ubuntu system (with musl libc). > > I'd like to install the necessary development tools (compilers, > libraries, headers, etc) in the Linux compat environment. It appears > that linux_base-c6 does not contain a package manager (yum or dnf). > What's the best way to install these tools? Did people have success > installing and using a package manager, or should I manually download > RPMs, or even compile from source? > > The wiki has this guide: https://wiki.freebsd.org/VIMAGE/Linux/CentOS55 > but it's rather old and I couldn't learn much from it. > > Alternatively I'd also be interested in cross compiling to Linux > directly from FreeBSD, if that's more practical. Still I'd need the > headers and libraries. Installing linux-c6-devtools will give you a C compiler. There are many other linux-c6-* ports that install additional libraries, but none of them install the corresponding headers. You could download -devel packages from http://mirror.centos.org/centos/6.9/ (os/ and updates/ subdirectories) and unpack them with tar.