From owner-freebsd-emulation Mon Apr 17 10:31:46 2000 Delivered-To: freebsd-emulation@freebsd.org Received: from atlrel2.hp.com (atlrel2.hp.com [156.153.255.202]) by hub.freebsd.org (Postfix) with ESMTP id 0CE8337BA3C for ; Mon, 17 Apr 2000 10:31:44 -0700 (PDT) (envelope-from marcel@cup.hp.com) Received: from adlmail.cup.hp.com (adlmail.cup.hp.com [15.0.100.30]) by atlrel2.hp.com (Postfix) with ESMTP id 3AF31827; Mon, 17 Apr 2000 13:31:42 -0400 (EDT) Received: from cup.hp.com (gauss.cup.hp.com [15.28.97.152]) by adlmail.cup.hp.com with ESMTP (8.8.6 (PHNE_17135)/8.7.3 TIS 5.0.1) id KAA14248; Mon, 17 Apr 2000 10:31:35 -0700 (PDT) Message-ID: <38FB4A77.C437E132@cup.hp.com> Date: Mon, 17 Apr 2000 10:31:35 -0700 From: Marcel Moolenaar Organization: Hewlett-Packard X-Mailer: Mozilla 4.72 [en] (X11; I; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: John Daniels Cc: freebsd-emulation@freebsd.org Subject: Re: linux application References: <20000416175640.51290.qmail@hotmail.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-emulation@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org John Daniels wrote: > With that said, if the API binaries are linked in, it would seem logical > that I would then then have to develop "under Linux" as you outlined -- but > wouldn't I need to "brand" the programs that I develop? (If they are not > branded, I would think that they would then only run under the linux > "development" shell.) And, if the API is implemented with *shared* > binaries, couldn't I just "brand" those and develop my programs under > FreeBSD? You only need to brand static binaries. Shared binaries have the name of the interpreter (dynamic linker) embedded in them, which automaticly tells what kind of binary it is. Note that branding an ELF file doesn't limit its use on other systems... > Also, I know that I have the Linux compatibility installed (I did that when > I installed the system and I am running Linux Netscape and Star Office), but > how can I know if I already have linux_devtools installed (I may have > installed it, I'm not sure)? See pkg_info(1). > Your remarks lead me to believe that as long as I am working in a "linux > shell" I am developing under linux, otherwise I am developing under FreeBSD. > Please let me know if this assumption is not correct. Technically it's not correct. Practically, it is. When you're using a Linux shell, then every external command will basicly be looked up under /compat/linux first (depending on path). This means that you use the Linux binaries if they are installed and the FreeBSD binaries otherwise (loosely speaking). Thus, within a Linux shell, you will use the Linux compiler and not the FreeBSD compiler (in general). This is not hardcoded anywhere and is therefore not a "rule". If you know how things work, you can easily change this behaviour and create a setup in which this doesn't work. But, again: In general your assumption is right. > Did you specifically mention C/C++ because that is what is supported by > linux_devtools? Yes. > Do I have to have be running the Linux versions of other > languages (e.g. Java) if I want to use them for development under the linux > shell? In general, if you are creating Linux binaries or need to link with Linux libraries (either at compile-time or at run-time), you need a Linux version of the language tools. Otherwise you should be able to use FreeBSD native tools. -- Marcel Moolenaar mail: marcel@cup.hp.com / marcel@FreeBSD.org tel: (408) 447-4222 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-emulation" in the body of the message