Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 7 Aug 2010 22:42:02 +0200 (CEST)
From:      Oliver Fromme <olli@lurza.secnetix.de>
To:        freebsd-questions@FreeBSD.ORG, eb30750@gmail.com
Subject:   Re: misc/149335: shell script runs on Linux but not on freebsd
Message-ID:  <201008072042.o77Kg2Gj017101@lurza.secnetix.de>
In-Reply-To: <AANLkTimRjxG6NC3PLxybkGnHfFXe5CW=oKGcqRROOUZu@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
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 <eb30750@gmail.com> 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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201008072042.o77Kg2Gj017101>