[arch-general] cannot run pacman in different operating system
Hello Dear Archians, I need to install arch from existing operating system. This is Mandriva 2010.0 64 bit: uname -a Linux luker500 2.6.33.5-server-2mnb #1 SMP Thu Jun 17 21:11:54 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux I am using (and contributing to): http://wiki.archlinux.org/index.php/Install_From_Existing_Linux Let me show you which steps I have done so far: $ ARCH=`uname -m` $ echo $ARCH x86_64 $ pwd /home/luke/archtest $ wget -q http://www.archlinux.org/packages/core/$ARCH/pacman/download/ http://mirrors.kernel.org/archlinux/core/os/x86_64/pacman-mirrorlist-2010082... http://www.archlinux.org/packages/core/$ARCH/libfetch/download/ http://www.archlinux.org/packages/core/$ARCH/libarchive/download/ http://www.archlinux.org/packages/core/$ARCH/openssl/download/ http://www.archlinux.org/packages/core/$ARCH/xz/download/ $ ls libarchive-2.8.4-1-x86_64.pkg.tar.gz openssl-1.0.0.a-3-x86_64.pkg.tar.gz pacman-mirrorlist-20100825-1-any.pkg.tar.gz libfetch-2.33-1-x86_64.pkg.tar.gz pacman-3.4.0-2-x86_64.pkg.tar.gz xz-4.999.9beta-5-x86_64.pkg.tar.gz $ for f in *.tar.gz ; do tar xzf $f ; done $ export LD_LIBRARY_PATH=/home/luke/archtest/usr/lib:$LD_LIBRARY_PATH $ echo $LD_LIBRARY_PATH /home/luke/archtest/usr/lib: $ ls -d /home/luke/archtest/usr/lib /home/luke/archtest/usr/lib/ $ export PATH=/home/luke/archtest/usr/bin:$PATH $ which pacman /home/luke/archtest/usr/bin/pacman So now it is time to try to run pacman: $ pacman --help -bash: /home/luke/archtest/usr/bin/pacman: No such file or directory I checked, this file really exists: $ file /home/luke/archtest/usr/bin/pacman /home/luke/archtest/usr/bin/pacman: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, stripped But I cannot even do ldd: $ ldd /home/luke/archtest/usr/bin/pacman /usr/bin/ldd: line 119: /home/luke/archtest/usr/bin/pacman: No such file or directory So additionally I checked strace output: $ strace /home/luke/archtest/usr/bin/pacman execve("/home/luke/archtest/usr/bin/pacman", ["/home/luke/archtest/usr/bin/pacm"...], [/* 78 vars */]) = -1 ENOENT (No such file or directory) dup(2) = 3 fcntl(3, F_GETFL) = 0x8002 (flags O_RDWR|O_LARGEFILE) fstat(3, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 33), ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f3180b61000 lseek(3, 0, SEEK_CUR) = -1 ESPIPE (Illegal seek) write(3, "strace: exec: No such file or di"..., 40strace: exec: No such file or directory ) = 40 close(3) = 0 munmap(0x7f3180b61000, 4096) = 0 exit_group(1) = ? And now I am really stuck. Is it related to my configuration or glibc incompatibility? What more information you need to track this issue? What shall I try, maybe compiling pacman from source? Regards, Luke
Am 31.08.2010 11:49, schrieb Łukasz Nowak:
So now it is time to try to run pacman:
$ pacman --help -bash: /home/luke/archtest/usr/bin/pacman: No such file or directory
Arch binaries assume the dynamic linker to be in /lib/ld-linux-x86-64.so.2, while most (all?) other distributions assume it to be in /lib64/ld-linux-x86-64.so.2: $ readelf -a $(which pacman) | grep interpreter [Requesting program interpreter: /lib/ld-linux-x86-64.so.2] $ readelf -a /some/mandriva/binary | grep interpreter [Requesting program interpreter: /lib64/ld-linux-x86-64.so.2] The "No such file or directory" is very misleading here, as the file that it is trying to open is the program interpreter, not pacman itself. A symlink should suffice: # ln -s /lib64/ld-linux-x86-64.so.2 /lib/ This problem does not exist on i686: The dynamic linker is /lib/ld-linux.so.2 here, on Arch or on any distribution out there.
Hello, 2010/8/31 Thomas Bächler <thomas@archlinux.org>:
Am 31.08.2010 11:49, schrieb Łukasz Nowak:
So now it is time to try to run pacman:
$ pacman --help -bash: /home/luke/archtest/usr/bin/pacman: No such file or directory
Arch binaries assume the dynamic linker to be in /lib/ld-linux-x86-64.so.2, while most (all?) other distributions assume it to be in /lib64/ld-linux-x86-64.so.2:
$ readelf -a $(which pacman) | grep interpreter [Requesting program interpreter: /lib/ld-linux-x86-64.so.2] $ readelf -a /some/mandriva/binary | grep interpreter [Requesting program interpreter: /lib64/ld-linux-x86-64.so.2]
The "No such file or directory" is very misleading here, as the file that it is trying to open is the program interpreter, not pacman itself.
A symlink should suffice: # ln -s /lib64/ld-linux-x86-64.so.2 /lib/
This problem does not exist on i686: The dynamic linker is /lib/ld-linux.so.2 here, on Arch or on any distribution out there.
Ach, thank you. I will update the page. You are right: $ ls /lib64/ld-linux-x86-64.so.2 /lib64/ld-linux-x86-64.so.2 $ ls /lib/ld-linux-x86-64.so.2 ls: cannot access /lib/ld-linux-x86-64.so.2: No such file or directory Regards, Luke PS. In meantime I just compiled pacman :) -- Łukasz Nowak IT Specialist email@lnowak.com http://lnowak.com/ Skype: Shufla jid: shufla@jabster.pl gg: 1157726 ``Use the Source, Luke...''
participants (2)
-
Thomas Bächler
-
Łukasz Nowak