Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-10 Thread Sergio Polini
Richard Fish:
 Unfortunately, even though I can get all the right libraries to
 load, I cannot get sound to work reliably on amd64.  Neither aoss
 nor vmdsp seem to work for me, either as a user or root.

That's very strange, because...

 However, I think I know how to make aoss work as a normal user on
 your system.  You should just need to:

 # chmod 4755 /emul/linux/x86/usr/lib/libaoss.so.0.0.0
 # ln -s /emul/linux/x86/usr/lib/libaoss.so /usr/lib32/libaoss.so

 The first command is just to make sure the library is setuid.

YOU ARE GREAT!!! 
I have too Gentoos, stable and testing.  I had only vmplayer 
installed in stable (the virtual machine is in another partition).
So I have:
a) emerged alsa-oss
b) emerged emul-linux-x86-soundlibs
c) chmoded and ln -sed as you have advised
and sound is working now both as root and as normal user!
Thanks!

If you have some spare time, I'ld like to understand why the symbolic 
link in /usr/lib32 is needed (and why your solution works on my 
system and not on yours).
But don't bother. I can imagine that you have something better to 
do ;-)

Tanks again
Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-09 Thread Richard Fish

On 11/9/06, Sergio Polini [EMAIL PROTECTED] wrote:

However: no preloading error message, but sound does not work.
BTW: are you sure sure that one can still set LD_PRELOAD to an
*absolute* path?


Actually, no.  You have to use the library name, so libaoss.so is
valid, /emul/.../libaoss.so is not.

However, the search path in this case is pretty limited.  I had to
make a symlink from /usr/lib32/libaoss.so to
/emul/linux/x86/usr/lib/libaoss.so to get aoss to preload as a normal
user.


Are you sure that that has not been reverted in glibc 2.4-r3?


Well I'm glibc-2.5 on both amd64 and x86, so I can't say for certain
what happens with 2.4, but yes, I believe it was dropped in all sane
versions of glibc.  In particular, none of my tests today on amd64 or
x86 revealed any significant problem in actually preloading the
libraries (other than the symlink issue I noted above, and of course,
needing to chmod 4755 the library to be preloaded).

FYI, I also reported the preloading problem via bugzilla way back when:

http://bugs.gentoo.org/show_bug.cgi?id=86844


 I'm going to try installing workstation on my amd64 desktop and see
 what I get.

Thanks!!!


Unfortunately, even though I can get all the right libraries to load,
I cannot get sound to work reliably on amd64.  Neither aoss nor vmdsp
seem to work for me, either as a user or root.

However, I think I know how to make aoss work as a normal user on your
system.  You should just need to:

# chmod 4755 /emul/linux/x86/usr/lib/libaoss.so.0.0.0
# ln -s /emul/linux/x86/usr/lib/libaoss.so /usr/lib32/libaoss.so

The first command is just to make sure the library is setuid.

For vmdsp, my best guess is that a 64-bit artsd won't communicate with
32-bit clients.  But that is just a guess.

FYI, on my x86 laptop both vmdsp and aoss work, although aoss produces
choppy audio.

HTH,
-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-08 Thread Hans-Werner Hilse
Hi,

On Wed, 8 Nov 2006 08:31:20 +0100 Sergio Polini [EMAIL PROTECTED]
wrote:

 [sp ~]$ aoss vmware 
 [2] 5598
 [sp ~]$ ERROR: ld.so: object 'libaoss.so' from LD_PRELOAD cannot be 
 preloaded: ignored.

What are the permissions on *this* one (aoss32 seems not to be for you,
so /emul/linux/... isn't relevant), i.e. /usr/lib/libaoss.so (and the
file it points to in case it's a symlink)?

You answered my last question about why you are mocking with chmod +s
with something along the lines of I felt like I had to. What makes
you think you have to? Why should those libraries be set with setuid?

-hwh
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-08 Thread Richard Fish

On 11/8/06, Hans-Werner Hilse [EMAIL PROTECTED] wrote:

You answered my last question about why you are mocking with chmod +s
with something along the lines of I felt like I had to. What makes
you think you have to? Why should those libraries be set with setuid?


This is necessary because vmware is a setuid executable, and you
cannot use LD_PRELOAD with setuid executables unless those libraries
are *also* setuid.

Sergio,  try doing chmod +s on /emul/linux/x86/usr/lib/libaoss.so

-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-08 Thread Sergio Polini
Dear Bo, Hans-Werner, and Richard,
I wish at first to thank you for your help.
Then, I think that a small recap could be useful.
Please, select a fixed font ;-)

a) vmwarearts (in vmware-dsp):

userlibvmdsp.so  result
--  ---  ---
normal  chmod -s no preload
rootchmod -s no /dev/dsp
normal  chmod +s no preload
rootchmod +s no /dev/dsp

b) aoss32 (in alsa-oss):

useremul/.../libaoss.so.0.0.0  result
--  -  --
normal  chmod -s   no preload
rootchmod -s   no preload
normal  chmod +s   no preload
rootchmod +s   no preload

c) aoss (in alsa-oss):

userlibaoss.so.0.0.0  result
--    --
normal  chmod -s  no preload
rootchmod -s  sound works
normal  chmod +s  no preload
rootchmod +s  sound works

As to:
Richard:
 Sergio,  try doing chmod +s on /emul/linux/x86/usr/lib/libaoss.so
There is no such file!

Now:

i) I can't understand why root can't open /dev/dsp when running 
vmwarearts. I can only guess that aoss works better ;-)

ii) suid and sgid bits look insignificant (!)

Hans-Werner Hilse:
 You answered my last question about why you are mocking with chmod
 +s with something along the lines of I felt like I had to. What
 makes you think you have to? Why should those libraries be set with
 setuid?

Sorry, my answer was evasive because I've googled a lot and can't 
remember where I've read that I had to ;-)
However, I also tried installing vmwaredsp-1.3 manually, and in the 
install script, runme.sh, there is the line:
install -c -m  64/libvmdsp.so $LIB64/libvmdsp.so
(but even the vmwarearts in this package does not work).
Richard's answer:

 This is necessary because vmware is a setuid executable,
 and you cannot use LD_PRELOAD with setuid executables
 unless those libraries are *also* setuid.

look very interesting, because, as far as I can understand

testing ~ # cd /opt/vmware/workstation/bin
testing bin # l
total 1872
-rwxr-xr-x 1 root root12292 Nov  1 00:20 vm-support*
-rwxr-xr-x 1 root root 6160 Nov  1 00:20 vmnet-bridge*
-rwxr-xr-x 1 root root   110872 Nov  1 00:20 vmnet-dhcpd*
-rwxr-xr-x 1 root root   118884 Nov  1 00:20 vmnet-natd*
-rwxr-xr-x 1 root root 5192 Nov  1 00:20 vmnet-netifup*
-rwxr-xr-x 1 root root 8140 Nov  1 00:20 vmnet-sniffer*
-rwxr-xr-x 1 root root 4574 Nov  1 00:20 vmplayer*
-rwxr-xr-x 1 root root 4946 Nov  1 00:20 vmrun*
-rwxr-xr-x 1 root root 4570 Nov  1 00:20 vmware*
-rwxr-xr-x 1 root root   268975 Nov  1 00:20 vmware-config.pl*
-rwxr-xr-x 1 root root   486368 Nov  1 00:20 vmware-loop*
-rwxr-xr-x 1 root root25488 Nov  1 00:20 vmware-mount.pl*
-rws--x--- 1 root vmware  10852 Nov  1 00:20 vmware-ping*
-rwxr-xr-x 1 root root90467 Nov  1 00:20 vmware-uninstall.pl*
-rwxr-xr-x 1 root root   694312 Nov  1 00:20 vmware-vdiskmanager*
testing bin #

my vmware *is not* setuid!
However, nothing changes if I do chmod +s on libaoss *and* vmware: 
sound only works when I am root, otherwise libaoss is not preloaded.

BTW, I've installed Ubunto 6.10 and looked at what happened.
Well vmwareesd... works!!!
Linux kernel: 2.6.17 i686
glibc: 2.4
libvmdsp.so: setuid (!)

I am in the dark. Also because googling around I can see that a 
similar preload problem occurs rather often in several different 
cases, but there is seldom a solution

Eventually I'll run vmware as root when I'll need sound ;-)

Thanks again
Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-08 Thread Sergio Polini
Me:
 As to:

 Richard:
  Sergio,  try doing chmod +s on /emul/linux/x86/usr/lib/libaoss.so

 There is no such file!

Sorry, Richard. I was looking in /emul/linux/x86/lib ;-))
However the results are those reported in my previous message.

Sergio

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-08 Thread Richard Fish

On 11/8/06, Sergio Polini [EMAIL PROTECTED] wrote:

 Sergio,  try doing chmod +s on /emul/linux/x86/usr/lib/libaoss.so
There is no such file!


Hold up.  Previously you posted:


LD_PRELOAD=${exec_prefix}/lib/libaoss.so${LD_PRELOAD:+:$LD_PRELOAD}

[...]

[sp ~]$ ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from
LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from
LD_PRELOAD cannot be preloaded: ignored.


If this file doesn't exist, then *that* is why preloading doesn't
work.  If instead you have emul/.../libaoss.so.0.0.0, then change
the LD_PRELOAD in aoss32 to:

LD_PRELOAD=${exec_prefix}/lib/libaoss.so.0.0.0${LD_PRELOAD:+:$LD_PRELOAD}

I would also add an echo for debugging after that:

echo running with LD_PRELOAD=$LD_PRELOAD


i) I can't understand why root can't open /dev/dsp when running
vmwarearts. I can only guess that aoss works better ;-)


Since preloading appears to work in this case (no error from that), I
am going to assume that this is actually a failure to contact artsd as
root.  Note that the effect of preloading is to fool vmware into
contacting artsd instead of opening /dev/dsp...so the error can
actually be slightly misreported.

Are you actually logged into KDE as root, or as your normal user?
What happens when you run artsplay
/usr/kde/3.5/share/sounds/KDE_Startup_1.ogg as root?  under your user
account?



ii) suid and sgid bits look insignificant (!)

look very interesting, because, as far as I can understand

testing ~ # cd /opt/vmware/workstation/bin

[snip]

-rwxr-xr-x 1 root root 4570 Nov  1 00:20 vmware*


This is a shell script (your clue is the size).  The actual binary
that executes the virtual machine (and this needs to produce sound) is
in /opt/vmware/workstation/lib/bin, and is named vmware-vmx.  It is
almost certainly setuid.

(BTW, I should have said vmware _uses_ setuid executables)


my vmware *is not* setuid!
However, nothing changes if I do chmod +s on libaoss *and* vmware:


No, don't make the shell script setuid.  That would be a security hole.


sound only works when I am root, otherwise libaoss is not preloaded.


I really don't understand why aoss would only work as root.  I suspect
a path or environment issue here, possibly a different library is
actually being loaded.  I suspect this has more to do with the actual
path to the library being loaded as root versus your user account.

I'm going to try installing workstation on my amd64 desktop and see what I get.

-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-08 Thread Sergio Polini
Richard Fish:
 On 11/8/06, Sergio Polini [EMAIL PROTECTED] wrote:
   Sergio,  try doing chmod +s on
   /emul/linux/x86/usr/lib/libaoss.so
 
  There is no such file!

 Hold up.  Previously you posted:
 [cut]
 If this file doesn't exist,

That file esists. I was looking in /emul/linux/x86/lib. ;-)

 If instead you have emul/.../libaoss.so.0.0.0, then change
 the LD_PRELOAD in aoss32 to:

 LD_PRELOAD=${exec_prefix}/lib/libaoss.so.0.0.0${LD_PRELOAD:+:$LD_PR
ELOAD}

 I would also add an echo for debugging after that:

 echo running with LD_PRELOAD=$LD_PRELOAD

If I write:

LD_PRELOAD=${exec_prefix}/lib/libaoss.so.0.0.0${LD_PRELOAD:+:
$LD_PRELOAD}   exec $@
echo running with LD_PRELOAD=$LD_PRELOAD

I get:
[sp ~]$ aoss32 vmware
ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so.0.0.0' from 
LD_PRELOAD cannot be preloaded: ignored.
(five times)

and the echo statement is not executed.
If I write:
  LD_PRELOAD=${exec_prefix}/lib/libaoss.so.0.0.0${LD_PRELOAD:+:
$LD_PRELOAD}  echo running with LD_PRELOAD=$LD_PRELOAD  exec $@

I get:
[sp ~]$ aoss32 vmware
running with LD_PRELOAD=

?
However: no preloading error message, but sound does not work.
BTW: are you sure sure that one can still set LD_PRELOAD to an 
*absolute* path? 

 Are you actually logged into KDE as root, or as your normal user?

Always as a normal user. I open a new root shell in Konsole when I 
wish to be root.

 What happens when you run artsplay
 /usr/kde/3.5/share/sounds/KDE_Startup_1.ogg as root?  under your
 user account?

I can hear the sound.

 This is a shell script (your clue is the size).  The actual binary
 that executes the virtual machine (and this needs to produce sound)
 is in /opt/vmware/workstation/lib/bin, and is named vmware-vmx.  It
 is almost certainly setuid.

Right. I apologize for my foolishness/laziness. Let me say that I was 
a bit tired yesterday evening ;-)

 I really don't understand why aoss would only work as root.  I
 suspect a path or environment issue here, possibly a different
 library is actually being loaded.  I suspect this has more to do
 with the actual path to the library being loaded as root versus
 your user account.

On Marc 27th, 2005 you wrote in a VMWare Forum:
 Ok, I got it figured out. It seems that in response to GLSA
 200408-16, Gentoo made a patch that in addition to fixing the
 LD_DEBUG vulnerability, moved the cleansing of the environment
 to before the values were saved. This part of the change is not in
 the official glibc CVS source, and the patch is not applied for
 glibc-2.3.4.20050125-r1 (currently marked for testing...).
 So Gentoo users will need to upgrade their glibc to at least
 2.3.4.20050125 to use LD_PRELOAD with setuid binaries.   

Are you sure that that has not been reverted in glibc 2.4-r3?

 I'm going to try installing workstation on my amd64 desktop and see
 what I get.

Thanks!!!

Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Bo Ørsted Andresen
On Tuesday 07 November 2006 06:54, Bo Ørsted Andresen wrote:
 On Tuesday 07 November 2006 06:44, Richard Fish wrote:
  On 11/4/06, Sergio Polini [EMAIL PROTECTED] wrote:
   `/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'
   cc -c -W -Wall -O2 -fPIC -o vmdsp.o ../vmdsp.c
   cc -shared -Wl,-version-script=../vmdsp.map -o libvmdsp.so
   vmdsp.o  -lpthread -ldl -lc
   /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/
  bi n/ld: libvmdsp.so: undefined versioned symbol name [EMAIL PROTECTED]
   /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/
  bi n/ld: failed to set dynamic section sizes: Bad value
   collect2: ld returned 1 exit status
   make[1]: *** [libvmdsp.so] Error 1
   rm vmdsp.o
   make[1]: Leaving directory
   `/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'
 
  Hmm, looks like building this is broken on AMD64 arches...too bad.

 http://bugs.gentoo.org/show_bug.cgi?id=150495

I've attached a patch for the ebuild on the bug that although not excactly 
optimal it works for me.

-- 
Bo Andresen


pgpxWyyfki1rv.pgp
Description: PGP signature


Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Sergio Polini
Richard Fish:
 Sorry for the late reply...I've been away for a couple of days.

That's very kind of you :-)

 Hmm, looks like building this is broken on AMD64 arches...too bad.

I'll check the patch submitted by Bo.

  testing ~ # ldd /usr/lib/libvmdsp.so
  ldd: warning: you do not have execution permission for
  `/usr/lib/libvmdsp.so'
  libpthread.so.0 = /lib/libpthread.so.0
  (0x2b944790f000) libdl.so.2 = /lib/libdl.so.2
  (0x2b9447a25000) libc.so.6 = /lib/libc.so.6
  (0x2b9447b29000) /lib64/ld-linux-x86-64.so.2
  (0x4000)

 Ah, libvmdsp.so is a 64-bit library.  I am pretty sure that vmware
 is still distributed as a 32-bit application, so yeah, preloading
 64-bit libraries won't work.

Sorry, but... are you sure that a 32-vs-64 bit compatibility problem 
can vanish when I run aoss vmware as root?
Sound works when I am root...

Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Sergio Polini
Bo Ørsted Andresen:
  http://bugs.gentoo.org/show_bug.cgi?id=150495

 I've attached a patch for the ebuild on the bug that although not
 excactly optimal it works for me.

Thanks! Now I've just to understand how to emerge an ebuild with a new 
patch ;-)))

Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Sergio Polini
Sergio Polini:
 Bo Ørsted Andresen:
   http://bugs.gentoo.org/show_bug.cgi?id=150495
 
  I've attached a patch for the ebuild on the bug that although not
  excactly optimal it works for me.

 Thanks! Now I've just to understand how to emerge an ebuild with a
 new patch ;-)))

Well, it was easy, but:
a) when I run vmwarearts as a normal user, I get:
vmwarearts ERROR: ld.so: object 'libvmdsp.so' from LD_PRELOAD cannot 
be preloaded: ignored.
and sound doesn't work;
b) when I run vmwarearts as root, I get a vmware messate Failed to 
open sound device /dev/dsp: No such device Virtual device sound will 
start disconnected.;
c) when I run aoss vmware as a normal user, I get:
ERROR: ld.so: object 'libaoss.so' from LD_PRELOAD cannot be preloaded: 
ignored.
d) when I run aoss vmware as root sound works!!!

I still think that there is something about permissions somewhere.

Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Sergio Polini
Richard Fish:
 Ah, libvmdsp.so is a 64-bit library.  I am pretty sure that vmware
 is still distributed as a 32-bit application, so yeah, preloading
 64-bit libraries won't work.

 Try changing the vmwarearts script to preload the library from
 /usr/lib32 instead of /usr/lib.

I've tried aoss32, i.e.:

#!/bin/sh

# A simple script to facilitate the use of the OSS compatibility 
library.
# Usage:
#   aoss command command options and arguments

if [ -d /proc/asound ]; then
  prefix=/emul/linux/x86/usr
  exec_prefix=${prefix}
  LD_PRELOAD=${exec_prefix}/lib/libaoss.so${LD_PRELOAD:+:$LD_PRELOAD} 
exec $@
else
  exec $@
fi
exit 1

But I've got (the same as root):

[sp ~]$ ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.
ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.

Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Richard Fish

On 11/7/06, Sergio Polini [EMAIL PROTECTED] wrote:

Richard Fish:
 Ah, libvmdsp.so is a 64-bit library.  I am pretty sure that vmware
 is still distributed as a 32-bit application, so yeah, preloading
 64-bit libraries won't work.

 Try changing the vmwarearts script to preload the library from
 /usr/lib32 instead of /usr/lib.

I've tried aoss32, i.e.:

But I've got (the same as root):

[sp ~]$ ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from
LD_PRELOAD cannot be preloaded: ignored.


What are the permissions on this?

-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-07 Thread Sergio Polini
Richard Fish:
  [sp ~]$ ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so'
  from LD_PRELOAD cannot be preloaded: ignored.

 What are the permissions on this?

a)
ls -l /emul/linux/x86/usr/lib/libaoss.so.0.0.0 - -rwxr-xr-x

[sp ~]$ aoss32 vmware 
[1] 5409
[sp ~]$ ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.
(five times)

testing ~ # aoss32 vmware 
[1] 5439
testing lib # ERROR: ld.so: 
object '/emul/linux/x86/usr/lib/libaoss.so' from LD_PRELOAD cannot be 
preloaded: ignored.
(five times)

b)
chmod +s libaoss.so.0.0.0
ls -l /emul/linux/x86/usr/lib/libaoss.so.0.0.0 - -rwsr-sr-x

[sp ~]$ aoss32 vmware 
[1] 5462
[sp ~]$ ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' from 
LD_PRELOAD cannot be preloaded: ignored.
(five times)

testing lib # aoss32 vmware 
[1] 5480
testing ~ # ERROR: ld.so: object '/emul/linux/x86/usr/lib/libaoss.so' 
from LD_PRELOAD cannot be preloaded: ignored.
(five times)

But:

testing ~ # aoss vmware 
[1] 5515
(sound works)

[sp ~]$ aoss vmware 
[2] 5598
[sp ~]$ ERROR: ld.so: object 'libaoss.so' from LD_PRELOAD cannot be 
preloaded: ignored.

Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-06 Thread Hans-Werner Hilse
Hi,

On Sun, 5 Nov 2006 12:55:58 +0100 Sergio Polini [EMAIL PROTECTED]
wrote:

 Since vmware-dsp (which is ~amd64) doesn't compile, I have:
 - emerged alsa-oss
 - chmod +s /usr/lib/libaoss.so.*
^^^
Why did you do that? Try setting it back and then use LD_PRELOAD. Your
normal user account can't possibly change to another user (probably
root in this case for /usr/lib/libaoss.*...).

 - created a script:

-hwh
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-06 Thread Sergio Polini
Hans-Werner Hilse:
 On Sun, 5 Nov 2006 12:55:58 +0100 Sergio Polini [EMAIL PROTECTED]

 wrote:
  Since vmware-dsp (which is ~amd64) doesn't compile, I have:
  - emerged alsa-oss
  - chmod +s /usr/lib/libaoss.so.*

 ^^^
 Why did you do that?

I did that because, as far as I have understood, I had to ;-)

  Try setting it back and then use LD_PRELOAD.

Done. Sound still not working, unless I run aoss vmware (or aoss 
wmplayer) as root.

 Your normal user account can't possibly change to another user
 (probably root in this case for /usr/lib/libaoss.*...).

I suspect that there is a glibc problem:
http://www.vmware.com/community/message.jspa?messageID=26228
Look at the posts by... Richard Fish ;-)

Sergio

-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-06 Thread Richard Fish

Sorry for the late reply...I've been away for a couple of days.

On 11/4/06, Sergio Polini [EMAIL PROTECTED] wrote:

`/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'
cc -c -W -Wall -O2 -fPIC -o vmdsp.o ../vmdsp.c
cc -shared -Wl,-version-script=../vmdsp.map -o libvmdsp.so
vmdsp.o  -lpthread -ldl -lc
/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bin/ld:
libvmdsp.so: undefined versioned symbol name [EMAIL PROTECTED]
/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bin/ld:
failed to set dynamic section sizes: Bad value
collect2: ld returned 1 exit status
make[1]: *** [libvmdsp.so] Error 1
rm vmdsp.o
make[1]: Leaving directory
`/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'


Hmm, looks like building this is broken on AMD64 arches...too bad.


testing ~ # ldd /usr/lib/libvmdsp.so
ldd: warning: you do not have execution permission for
`/usr/lib/libvmdsp.so'
libpthread.so.0 = /lib/libpthread.so.0 (0x2b944790f000)
libdl.so.2 = /lib/libdl.so.2 (0x2b9447a25000)
libc.so.6 = /lib/libc.so.6 (0x2b9447b29000)
/lib64/ld-linux-x86-64.so.2 (0x4000)


Ah, libvmdsp.so is a 64-bit library.  I am pretty sure that vmware is
still distributed as a 32-bit application, so yeah, preloading 64-bit
libraries won't work.

Try changing the vmwarearts script to preload the library from
/usr/lib32 instead of /usr/lib.

-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-06 Thread Richard Fish

On 11/5/06, Sergio Polini [EMAIL PROTECTED] wrote:

#!/bin/bash
LD_PRELOAD=libaoss.so exec /opt/vmware/workstation/bin/vmware 

Now:
i) if I run the script as myself, sound doesn't work and I get
ERROR: ld.so: object 'libaoss.so' from LD_PRELOAD cannot be preloaded:
ignored.


This is the same 32-vs-64 bit problem as with vmwaredsp.
Unfortunately I don't see any obvious way to get alsa-oss to build
32-bit version.

-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-06 Thread Richard Fish

On 11/6/06, Sergio Polini [EMAIL PROTECTED] wrote:

I suspect that there is a glibc problem:
http://www.vmware.com/community/message.jspa?messageID=26228
Look at the posts by... Richard Fish ;-)


Nah, not the same problem.  In my case it was a gentoo-specific glibc
patch that was messing up.  I think yours 32-vs-64 bit compatibility.

-Richard
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-06 Thread Bo Ørsted Andresen
On Tuesday 07 November 2006 06:44, Richard Fish wrote:
 On 11/4/06, Sergio Polini [EMAIL PROTECTED] wrote:
  `/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'
  cc -c -W -Wall -O2 -fPIC -o vmdsp.o ../vmdsp.c
  cc -shared -Wl,-version-script=../vmdsp.map -o libvmdsp.so
  vmdsp.o  -lpthread -ldl -lc
  /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bi
 n/ld: libvmdsp.so: undefined versioned symbol name [EMAIL PROTECTED]
  /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bi
 n/ld: failed to set dynamic section sizes: Bad value
  collect2: ld returned 1 exit status
  make[1]: *** [libvmdsp.so] Error 1
  rm vmdsp.o
  make[1]: Leaving directory
  `/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'

 Hmm, looks like building this is broken on AMD64 arches...too bad.

http://bugs.gentoo.org/show_bug.cgi?id=150495

-- 
Bo Andresen


pgp2IWOuqwtfJ.pgp
Description: PGP signature


Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-05 Thread Sergio Polini
Richard Fish:
 The workaround to this is to use a wrapper such as aoss or
 vmware-dsp that fakes out the application when it tries to open
 /dev/dsp and uses another audio API instead (alsa for aoss, esd or
 artsd for vmware-dsp).

Since vmware-dsp (which is ~amd64) doesn't compile, I have:
- emerged alsa-oss
- chmod +s /usr/lib/libaoss.so.*
- created a script:

#!/bin/bash
LD_PRELOAD=libaoss.so exec /opt/vmware/workstation/bin/vmware 

Now:
i) if I run the script as myself, sound doesn't work and I get
ERROR: ld.so: object 'libaoss.so' from LD_PRELOAD cannot be preloaded: 
ignored.
I get the same result if I run aoss vmware.
As to ldd /usr/lib/libaoss.so.0.0.0:
libalsatoss.so.0 = /usr/lib/libalsatoss.so.0 
(0x2b09ff97f000)
libc.so.6 = /lib/libc.so.6 (0x2b09ffa89000)
libasound.so.2 = /usr/lib/libasound.so.2 (0x2b09ffcb4000)
libm.so.6 = /lib/libm.so.6 (0x2b09ffe8b000)
libdl.so.2 = /lib/libdl.so.2 (0x2b09fffe)
libpthread.so.0 = /lib/libpthread.so.0 (0x2b0a000e4000)
/lib64/ld-linux-x86-64.so.2 (0x4000)

ii) if I run the script as root, sound works!

So, it looks like a matter of permissions, but I can't guess what I 
should change. I hope that you can ;-)

Cheers
Sergio
-- 
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-04 Thread Richard Fish

On 11/4/06, Sergio Polini [EMAIL PROTECTED] wrote:

Sound does not work. Sometimes (not always) I get a message
like cannot connect to /dev/dsp.
Even if I do not get that message, even if the sound card looks
connected (no red x) sound is not working.
I've found a VMWare document about a wrapper:


The problem is that /dev/dsp is the legacy OSS api, and does not
support dmix (software mixing of audio).  Thus only one application
can access /dev/dsp at a time unless your card supports hardware
mixing.  So most likely, /dev/dsp is already in use by some app.

The workaround to this is to use a wrapper such as aoss or vmware-dsp
that fakes out the application when it tries to open /dev/dsp and uses
another audio API instead (alsa for aoss, esd or artsd for
vmware-dsp).

http://kb.vmware.com/vmtnkb/search.do?cmd=displayKCdocType=kcexternalId=1611sliceId=SAL_Public

but it looks suited for versions 3.x, 4.x, and 5.0.x.
Moreover, I've installed it and got:


FYI, there is an ebuild available for this...emerge vmare-dsp.


[sp ~]$ ERROR: ld.so: object 'libvmdsp.so' from LD_PRELOAD cannot be
preloaded: ignored.


What does ldd /usr/lib/libvmdsp* report?  (or whatever directory
libvmdsp got installed to..)

-Richard

PS:The real fix for this is for VMWare to *stop* using the deprecated
OSS API for sound, and implement real ALSA compatibility.  I highly
recommend sending this request to them!
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] WinXP under VMWare: no sound

2006-11-04 Thread Sergio Polini
Richard Fish:
 On 11/4/06, Sergio Polini [EMAIL PROTECTED] wrote:
  Sound does not work. Sometimes (not always) I get a message
  like cannot connect to /dev/dsp.
  Even if I do not get that message, even if the sound card looks
  connected (no red x) sound is not working.
  I've found a VMWare document about a wrapper:

 The problem is that /dev/dsp is the legacy OSS api, and does not
 support dmix (software mixing of audio).  Thus only one application
 can access /dev/dsp at a time unless your card supports hardware
 mixing.  So most likely, /dev/dsp is already in use by some app.

alsasound?
kde? even if I have auto-suspend enabled?

 The workaround to this is to use a wrapper such as aoss or
 vmware-dsp that fakes out the application when it tries to open
 /dev/dsp and uses another audio API instead (alsa for aoss, esd or
 artsd for vmware-dsp).

 http://kb.vmware.com/vmtnkb/search.do?cmd=displayKCdocType=kcexte
rnalId=1611sliceId=SAL_Public

  but it looks suited for versions 3.x, 4.x, and 5.0.x.
  Moreover, I've installed it and got:

 FYI, there is an ebuild available for this...emerge vmare-dsp.

Oops! ;-)
It emerged app-emulation/emul-linux-x86-soundlibs-2.3 too (Im running 
Gentoo AMD64), but then:

01:56:32 (200.82 KB/s) - `/usr/portage/distfiles/vmwaredsp-1.3.tar.gz' 
saved [52412/52412]

 * checking ebuild checksums ;-) ...
  
[ ok ]
 * checking auxfile checksums ;-) ...   
  
[ ok ]
 * checking miscfile checksums ;-) ...  
  
[ ok ]
 * checking vmwaredsp-1.3.tar.gz ;-) ...
  
[ ok ]
 Unpacking source...
 Unpacking vmwaredsp-1.3.tar.gz 
to /var/tmp/portage/vmware-dsp-1.3/work
 Source unpacked.
 Compiling source 
in /var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3 ...
 * Building aRts support only.
make -C 32 default
make[1]: Entering directory 
`/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'
cc -c -W -Wall -O2 -fPIC -o vmdsp.o ../vmdsp.c
cc -shared -Wl,-version-script=../vmdsp.map -o libvmdsp.so 
vmdsp.o  -lpthread -ldl -lc
/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bin/ld: 
libvmdsp.so: undefined versioned symbol name [EMAIL PROTECTED]
/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bin/ld: 
failed to set dynamic section sizes: Bad value
collect2: ld returned 1 exit status
make[1]: *** [libvmdsp.so] Error 1
rm vmdsp.o
make[1]: Leaving directory 
`/var/tmp/portage/vmware-dsp-1.3/work/vmwaredsp-1.3/src/32'
make: *** [default] Error 2

!!! ERROR: app-emulation/vmware-dsp-1.3 failed.
Call stack:
  ebuild.sh, line 1546:   Called dyn_compile
  ebuild.sh, line 937:   Called src_compile
  vmware-dsp-1.3.ebuild, line 58:   Called die

!!! (no error message)
!!! If you need support, post the topmost build error, and the call 
stack if relevant.

:-(

  [sp ~]$ ERROR: ld.so: object 'libvmdsp.so' from LD_PRELOAD cannot
  be preloaded: ignored.

 What does ldd /usr/lib/libvmdsp* report?  (or whatever directory
 libvmdsp got installed to..)

From my former install (1611_fvmwaredsp-1.3.tgz):

testing ~ # ldd /usr/lib/libvmdsp.so
ldd: warning: you do not have execution permission for 
`/usr/lib/libvmdsp.so'
libpthread.so.0 = /lib/libpthread.so.0 (0x2b944790f000)
libdl.so.2 = /lib/libdl.so.2 (0x2b9447a25000)
libc.so.6 = /lib/libc.so.6 (0x2b9447b29000)
/lib64/ld-linux-x86-64.so.2 (0x4000)


 PS:The real fix for this is for VMWare to *stop* using the
 deprecated OSS API for sound, and implement real ALSA
 compatibility.  I highly recommend sending this request to them!

Sure, but first I'ld like to get sound working ;-)

Thanks
Sergio

-- 
gentoo-user@gentoo.org mailing list