From owner-freebsd-questions@FreeBSD.ORG Sat Aug 7 20:42:20 2010 Return-Path: Delivered-To: freebsd-questions@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C429A1065672 for ; Sat, 7 Aug 2010 20:42:20 +0000 (UTC) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [IPv6:2a01:170:102f::2]) by mx1.freebsd.org (Postfix) with ESMTP id 443FF8FC18 for ; Sat, 7 Aug 2010 20:42:20 +0000 (UTC) Received: from lurza.secnetix.de (localhost [127.0.0.1]) by lurza.secnetix.de (8.14.3/8.14.3) with ESMTP id o77Kg2kR017102; Sat, 7 Aug 2010 22:42:17 +0200 (CEST) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.14.3/8.14.3/Submit) id o77Kg2Gj017101; Sat, 7 Aug 2010 22:42:02 +0200 (CEST) (envelope-from olli) Date: Sat, 7 Aug 2010 22:42:02 +0200 (CEST) Message-Id: <201008072042.o77Kg2Gj017101@lurza.secnetix.de> From: Oliver Fromme To: freebsd-questions@FreeBSD.ORG, eb30750@gmail.com In-Reply-To: X-Newsgroups: list.freebsd-questions User-Agent: tin/1.8.3-20070201 ("Scotasay") (UNIX) (FreeBSD/6.4-PRERELEASE-20080904 (i386)) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.3.4 (lurza.secnetix.de [127.0.0.1]); Sat, 07 Aug 2010 22:42:18 +0200 (CEST) Cc: Subject: Re: misc/149335: shell script runs on Linux but not on freebsd X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-questions@FreeBSD.ORG, eb30750@gmail.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Aug 2010 20:42:20 -0000 Sorry for the late reply, I don't have much time currently. Maybe someone else from the -questions list can jump in, because I don't have much experience with vmware (I prefer qemu or virtual box). Paul Lambert wrote: > Thanks for the reply. I am attaching the bash output from the shell > script. This script implements RPMs so I am sure that I need the linux > module. I had previously found a guide on how to install RPMs on FreeBSD. > I have a printer that has an RPM that allows it to work on Linus. So I > would think that I will need the Linux module in the future. > > I previously had made the "stat" change to the shell script and that part > works. But, the bash shell is reporting an 'od" error. > > Finally, how much performance do you lose with the linux module emulator? Not much, probably none at all. Some people even say that Linux binaries run faster on FreeBSD than they run on Linux, because they benefit from the better network code and VM system. Anyway, the "linuxulator" isn't really an emulator, it's rather an ABI-level compatibility layer, very similar to the i386 (32bit) compatibility layer on FreeBSD/amd64 (64bit). > Do you believe I only need the emulator to get VMware installed or will it > make other linux calls that are not part of FreeBSD? I'm afraid you won't be able to install vmware this way. I suggest you look at the emulator/vmware* ports in the ports collection. > BRSINC-VM02# bash -vx VMware-Player-3.1.0-261024.x86_64.bundle > [...] > # XXX: put extraction in its own function > MAGIC_NUMBER=`od -An -t u4 -N 4 -aj > $MAGIC_OFFSET "$file" | tr -d ' '` There's a bogus line break which is causing this particular parsing error. Either join the lines, or put a backslash at the end of the first line (behind -aj). But I'm afraid this is the smallest of the problems. I suspect you won't be able to get this script to run correctly on FreeBSD, because it seems to do too many linux-specific things. Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M. Handelsregister: Registergericht Muenchen, HRA 74606, Geschäftsfuehrung: secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün- chen, HRB 125758, Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart FreeBSD-Dienstleistungen, -Produkte und mehr: http://www.secnetix.de/bsd "And believe me, as a C++ programmer, I don't hesitate to question the decisions of language designers. After a decent amount of C++ exposure, Python's flaws seem ridiculously small." -- Ville Vainio