**** BEGIN LOGGING AT Fri Sep 02 02:59:58 2016 Sep 02 09:33:31 ~flasher Sep 02 09:33:31 [flasher] at http://www.jedge.com/n810/flasher/maemo_flasher-3.5_2.5.2.2.tar.gz (also .exe!), or http://www.chakra-project.org/ccr/packages.php?ID=5027 or generally http://www.google.com/search?q=maemo_flasher-3.5_2.5.2.2.tar.gz. HARMattan(N9): https://aur.archlinux.org/packages/fl/flasher-harmattan/flasher-harmattan.tar.gz, or -- list of filenames/md5sums: http://pastebin.com/sYKdNJSH, or http://galif.eu/nokia/ Sep 02 09:37:11 you might want ~flashing Sep 02 09:38:56 * APic cannot execute flasher-3.5 Sep 02 09:39:02 Probably because i have a 64Bit-Environment Sep 02 09:39:08 And the Binary is 32 Bit Sep 02 09:39:08 yeah Sep 02 09:39:13 ~flashing Sep 02 09:39:13 methinks maemo-flashing is http://wiki.maemo.org/Updating_the_tablet_firmware, or - on linux PC - download&extract http://maemo.cloud-7.de/maemo5/patches_n_tools/maemo-my-private-workdir.tgz, cd into it, do sudo ./flash-it-all.sh; or see ~flashing-cmdline, or see ~lazyflashing Sep 02 09:39:36 Does the „private Workdir“ get around this Issue? Sep 02 09:39:41 *leech* Sep 02 09:40:03 dont remember, probabbly not Sep 02 09:40:19 you have to instal lib32-compat yourself Sep 02 09:40:20 Then i need a 32Bit-Chroot Sep 02 09:40:24 Ah, or that Sep 02 09:40:29 nope, just compat libs Sep 02 09:40:30 Then i will get /lib32 and Stuff, right? Sep 02 09:40:35 (Debian 8.5) Sep 02 09:40:37 depends on distro Sep 02 09:40:39 Ok Sep 02 09:42:14 ~0xffff Sep 02 09:42:15 well, 0xffff is https://github.com/pali/0xFFFF, or http://talk.maemo.org/showthread.php?t=87996 Sep 02 09:42:19 APic: ^ Sep 02 09:43:25 Ah Sep 02 09:43:33 So i can roll my own 64Bit-Flasher? Sep 02 09:43:34 Great Sep 02 09:43:51 ~tell APic about lazyflashing Sep 02 09:45:13 https://cascardo.eti.br/blog/GNU_libc_and_Linux/ Sep 02 09:45:21 * DocScrutinizer05 would appreciate when APic tests it Sep 02 09:45:31 Ok Sep 02 09:45:35 Is that already 64Bit, too? Sep 02 09:46:03 try it Sep 02 09:46:59 ceene, you can always install some old distro Sep 02 09:47:13 KotCzarny: yeah, i know Sep 02 09:47:22 just thought it was an interesting read, although well known around here Sep 02 09:47:55 easy debian project provides some patches to be able to run a more modern distro on power kernel Sep 02 09:52:58 DocScrutinizer05: http://nopaste.linux-dev.org/?1119836 Sep 02 09:53:12 Does Debian 8.5 have a Package for libusb-32Bit? Sep 02 09:53:33 Or maybe i can just aptitude install libusb:32 or something? Sep 02 09:54:16 APic: shit Sep 02 09:54:26 apt-get install libusb-0.1-4:i386 should do it Sep 02 09:55:27 Nope Sep 02 09:55:32 E: Paket libusb-0.1-4 kann nicht gefunden werden. Sep 02 09:56:20 Maybe i shall really rather use the 0xFFFF; You should adopt that in Your Script too ☺ Sep 02 09:56:25 apt-cache search libusb Sep 02 09:57:01 Debian doesn't have 32-bit repos by default on 64-bit OS Sep 02 09:57:08 you need to add the arch somehow I forget Sep 02 09:57:17 echo "foreign-architecture i386" > /etc/dpkg/dpkg.cfg.d/multiarch Sep 02 09:57:20 aaah right Sep 02 09:58:10 apic: try apt-cache search libusb|grep 0.1 Sep 02 09:58:39 libusb-0.1-4 - Userspace USB-Programmierbibliothek Sep 02 09:58:40 libusb++-0.1-4c2 - userspace C++ USB programming library Sep 02 09:59:03 dpkg: Fehler: Konfigurationsfehler: /etc/dpkg/dpkg.cfg.d/multiarch:1: unbekannte Option »foreign-architecture« Sep 02 09:59:06 That was not it B-( Sep 02 09:59:12 or i can simply put that lib somewhere Sep 02 09:59:27 or better, download from slackware32 :P Sep 02 09:59:34 B-) Sep 02 10:00:01 But i would like Multiarch anyhow Sep 02 10:00:15 well, my script did sth similar already Sep 02 10:00:53 dpkg --add-architecture i386 Sep 02 10:00:56 Maybe that helps Sep 02 10:01:06 At least that is from official https://wiki.debian.org/Multiarch/HOWTO#Configuring_architectures Sep 02 10:01:06 I think I even included the debian lib Sep 02 10:01:26 Yah, but libusb obviously needs other Libs Sep 02 10:02:06 Yup Sep 02 10:02:22 Now „apt-get update“ leeches i386 Package-Lists Sep 02 10:02:25 Win o/ Sep 02 10:02:28 ☺ Sep 02 10:02:59 Now „apt-get install libusb-0.1-4:i386“ works and installs: gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386 Sep 02 10:03:09 :) Sep 02 10:03:12 ☺ Sep 02 10:03:18 madd to wiki maybe Sep 02 10:06:08 Ok Sep 02 10:06:35 DocScrutinizer05: Now the Script runs Sep 02 10:06:41 Suitable USB device not found, waiting. Sep 02 10:06:50 Probably i need to connect it without USB-Hub Sep 02 10:08:04 Erasing CMT: 54% Sep 02 10:08:05 o/ Sep 02 10:08:37 APic: could you please provide the lib for my script? Sep 02 10:08:59 doc, he had to install more than one lib Sep 02 10:09:02 gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386? Sep 02 10:09:09 yes Sep 02 10:09:16 Ok Sep 02 10:09:30 and debian lib32 expect ld.so in /lib32 etc Sep 02 10:09:49 so you will have either run via chroot or symlink it to /somewhere Sep 02 10:09:57 I'm smarter than debian Sep 02 10:10:10 Maybe Your Script should rather do: „dpkg --add-architecture i386 && apt-get install libusb-0.1-4:i386“ Sep 02 10:10:11 and than you ;-P Sep 02 10:10:16 its not that hard to be smarter than debian nowadays Sep 02 10:10:22 sorry that's BS Sep 02 10:10:23 Well Sep 02 10:10:26 Not _everybody_ has Debian Sep 02 10:10:50 that's why i mentioned chrooting Sep 02 10:10:51 When i up the Libs, it works on Slackware too Sep 02 10:10:54 And NixOS and whatever Sep 02 10:10:58 but doc thinks he is smarter Sep 02 10:11:06 Doc is the Man ☺ Sep 02 10:11:25 Hm Sep 02 10:11:31 Where are the 32Bit-Libs? Sep 02 10:11:37 There is no /usr/lib32 Sep 02 10:11:41 do ldd on the library Sep 02 10:11:43 you will see Sep 02 10:11:45 k Sep 02 10:11:49 or on flasher itself Sep 02 10:12:45 libc.so.6 => /lib/i386-linux-gnu/i686/cmov/libc.so.6 (0xf7589000) Sep 02 10:12:50 Ok Sep 02 10:12:57 but notice ld location Sep 02 10:13:04 its not movable Sep 02 10:13:24 Whoah Sep 02 10:13:28 Tons of Stuff Sep 02 10:13:42 Lots of Symlinks too Sep 02 10:13:44 o.O Sep 02 10:14:16 [5.0.7]apic@Ant:/lib/i386-linux-gnu> find | nopaste-it Sep 02 10:14:21 http://nopaste.linux-dev.org/?1119837 Sep 02 10:14:36 I think we really should just add to the WiKi that You need a 32Bit-Environment Sep 02 10:14:39 I don't want the whole dir Sep 02 10:14:42 Modern Distros should just handle that Sep 02 10:14:50 apic,nah, chroot is enough Sep 02 10:14:55 gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386 Sep 02 10:15:06 Yes, that are the Packages Sep 02 10:15:10 Do You need the .dpkg? Sep 02 10:15:23 no Sep 02 10:15:29 s/dpkg/deb/ Sep 02 10:15:30 APic meant: Do You need the .deb? Sep 02 10:15:31 the binaries Sep 02 10:16:01 did you look into the script? Sep 02 10:16:06 libmemusage.so etc? Sep 02 10:16:12 Not really deeply Sep 02 10:16:20 just things from ldd flasher-3.5 Sep 02 10:16:36 Ah Sep 02 10:16:50 At the Moment i am trying to get an Account on WiKi.Maemo.Org Sep 02 10:16:59 ouch Sep 02 10:17:02 But if You will update Your Script there anyhow, i will not need that ;) Sep 02 10:18:07 Okay, so it LD_PRELOADs Stuff Sep 02 10:18:15 So i do only need the Dependencies Sep 02 10:19:06 That is probably only: libc.so.6 => /lib/i386-linux-gnu/i686/cmov/libc.so.6 (0xf751c000) then Sep 02 10:19:49 lrwxrwxrwx 1 root root 12 Feb 29 2016 libc.so.6 -> libc-2.19.so Sep 02 10:20:06 f42334db538ccd1a5408551af03b65422c110960 libc-2.19.so Sep 02 10:21:57 http://tmp.apic.name/libc-2.19.so Sep 02 10:22:00 There You are ☺ Sep 02 10:25:08 it's all in ldd maemo_flasher-3.5_2.5.2.2/flasher-3.5 that is in "gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386gcc-4.9-base:i386 libc6:i386 libc6-i686:i386 libgcc1:i386" too Sep 02 10:28:03 alas _you_ can't test now anymore if it really works :-) Sep 02 10:36:23 True Sep 02 10:37:35 So maybe „linux-gate.so.1 (0xf76f0000)“ is needed, too Sep 02 10:37:48 /lib/ld-linux.so.2 seems to work with the 64-Bit-Linker Sep 02 10:38:17 Then there is the provided libusb-0.1.so.4 and the libc.so.6 i upped, so that should really suffice ☺ Sep 02 10:38:39 (In the four Lines of „ldd flasher-3.5“) Sep 02 10:39:01 linux-gate is virtual dependency from kernel Sep 02 10:39:03 ld-linux.so.2: symbolic link to i386-linux-gnu/ld-2.19.so Sep 02 10:39:06 notreal Sep 02 10:39:07 Uh oh Sep 02 10:40:10 Where the Heck is the 64-Bit-ld then? Sep 02 10:40:18 Ah Sep 02 10:40:23 /lib64 Sep 02 10:40:24 you have all in ldd output Sep 02 10:40:24 ☺ Sep 02 10:44:47 could you pastebin the result of ldd ? Sep 02 10:45:14 and maybe also of your apt-get install run Sep 02 10:49:03 * APic no longer has the Terminal with the apt-get-Run open, sorry Sep 02 10:49:27 http://nopaste.linux-dev.org/?1119838 Sep 02 10:49:56 But APT logs, does jnot it? Sep 02 10:50:00 -j Sep 02 10:50:53 Yup Sep 02 10:50:54 Mompls Sep 02 10:51:28 http://nopaste.linux-dev.org/?1119839 There You are ☺ Sep 02 10:52:05 seems what I'd need is /lib/i386-linux-gnu/libusb-0.1.so.4 and /lib/i386-linux-gnu/i686/cmov/libc.so.6 , the latter just finished wget Sep 02 10:55:31 lrwxrwxrwx 1 root root 19 Okt 21 2014 libusb-0.1.so.4 -> libusb-0.1.so.4.4.4 Sep 02 10:56:10 http://tmp.apic.name/libusb-0.1.so.4.4.4 Sep 02 11:00:48 grrr Sep 02 11:00:56 APic: thanks Sep 02 11:01:23 You are welcome. Sep 02 11:02:05 hmm, could you do me a favor and test a little hack? Sep 02 11:02:10 Sure Sep 02 11:03:41 copy /lib/i386-linux-gnu/i686/cmov/libc.so.6 and /lib/i386-linux-gnu/libusb-0.1.so.4 into maemo-my-private-workdir Sep 02 11:04:28 rename /lib/i386-linux-gnu/: mv /lib/i386-linux-gnu/ /lib/i386-linux-gnu-XXX/ Sep 02 11:05:06 Done Sep 02 11:05:31 then test that flasher fails to run: cd maemo-my-private-workdir; maemo_flasher-3.5_2.5.2.2/flasher-3.5 Sep 02 11:06:19 Yes Sep 02 11:06:20 Fails Sep 02 11:06:23 good Sep 02 11:06:37 ☺ Sep 02 11:07:30 Can i move it back, or does the Test continue? Sep 02 11:07:30 now: LD_PRELOAD=./libusb-0.1.so.4.4.4:./libc.so.6 maemo_flasher-3.5_2.5.2.2/flasher-3.5 Sep 02 11:07:32 Ah Sep 02 11:07:35 ☺ Sep 02 11:07:45 * APic too impatient Sep 02 11:08:20 Still does not work Sep 02 11:08:26 damn!! Sep 02 11:08:31 -_- Sep 02 11:09:36 Probably You really need the 32-Bit-ld Sep 02 11:09:42 LD_TRACE_LOADED_OBJECTS=yes LD_PRELOAD=./libusb-0.1.so.4.4.4:./libc.so.6 maemo_flasher-3.5_2.5.2.2/flasher-3.5 Sep 02 11:10:05 Same Error, no further Output than: zsh: datei oder Verzeichnis nicht gefunden: maemo_flasher-3.5_2.5.2.2/flasher-3.5 Sep 02 11:10:19 huh? Sep 02 11:10:57 That is the error i get all the Time Sep 02 11:11:07 Of Course „File or Directory not found“ is a spurious Error Sep 02 11:11:34 yeah, maximum useless error message when a lib is missing Sep 02 11:11:34 It just means the Linker fails, and probably You really need to provide/call the 32-Bit-ld-linux Sep 02 11:12:15 32bit ldlinux? Sep 02 11:12:17 wow Sep 02 11:12:23 never heard of that Sep 02 11:12:55 /lib/i386-linux-gnu-XXX/ld-2.19.so Sep 02 11:13:04 Let us try to put that in Front of the Binary Sep 02 11:13:45 ./flasher-3.5: error while loading shared libraries: libusb-0.1.so.4: cannot open shared object file: No such file or directory Sep 02 11:13:49 Yup Sep 02 11:13:49 weird, why would it need to be a 32bit version? the ELF format of 32bit binaries is ok for the 64bit ld Sep 02 11:13:52 Now it searches for the Libs Sep 02 11:13:59 So LD_PRELOAD would work now probably Sep 02 11:14:16 That is a good Point that it would not actually be needed, yah ;) Sep 02 11:15:07 ok wait a minute Sep 02 11:15:13 [5.0.7]{2}apic@Ant:~/maemo-my-private-workdir> LD_PRELOAD=./libusb-0.1.so.4.4.4:./libc.so.6 /lib/i386-linux-gnu-XXX/ld-2.19.so maemo_flasher-3.5_2.5.2.2/flasher-3.5 Sep 02 11:15:16 That one works. Sep 02 11:15:23 flasher v2.5.2 (Oct 21 2009) Sep 02 11:16:13 wow! Sep 02 11:16:17 ☺ Sep 02 11:16:25 thanks, that's what I planned to ask you for Sep 02 11:17:12 now please rename /lib/i386-linux-gnu-XXX back to correct name Sep 02 11:17:28 I don't think you would usually use a 64-bit ld-linux to load 32-bit programs. Sep 02 11:17:37 Done Sep 02 11:17:47 lrwxrwxrwx 1 root root 22 Feb 18 2016 /lib/ld-linux.so.2 -> ../lib32/ld-linux.so.2 Sep 02 11:17:57 Maxdamantus: Yah, probably it _would_ work, but does not _want_ to work because of a Sanity-Check ;) Sep 02 11:18:18 I have that on my system, which is the normal path hardcoded into 32-bit ELFs. Sep 02 11:18:23 lrwxrwxrwx 1 root root 32 Feb 29 2016 ld-linux-x86-64.so.2 -> /lib/x86_64-linux-gnu/ld-2.19.so Sep 02 11:18:39 (/lib64/) Sep 02 11:19:49 I think it's typically different on Debian. Sep 02 11:20:14 phhhh http://paste.opensuse.org/39205569 Sep 02 11:20:53 ld != ldd Sep 02 11:21:07 shh, doc is SMARTER Sep 02 11:21:09 ;) Sep 02 11:21:29 lol, „bfd“ reminded me of BrainFuck ;) Sep 02 11:22:23 ld-linux = ldd Sep 02 11:22:40 ld is for linking binaries together to new binaries. Sep 02 11:22:59 *nod* Sep 02 11:23:57 But no, „ldd“ is also not ld-linux, it really just prints the Stuff ld-linux will link Sep 02 11:24:03 I guess you're right: http://paste.opensuse.org/82811691 Sep 02 11:24:13 ld-linux-Dumper i would call it Sep 02 11:24:28 Well, ldd is usually a shell script that invokes ld-linux. Sep 02 11:24:29 man ldd: ldd - print shared library dependencies Sep 02 11:24:54 I think it used to typically just be a symlink to ld-linux. Sep 02 11:25:24 note that for that to work, ld-linux needs to have dependency printing functionality built-in. Sep 02 11:25:24 just read the man page Sep 02 11:25:27 for details Sep 02 11:26:05 Yup Sep 02 11:26:19 $ /lib64/ld-linux-x86-64.so.2 --list `which ls` Sep 02 11:30:16 binfmtbinfmt fsckng magic Sep 02 11:30:43 jr@saturn:~/mymaemo-workdir/maemo-my-private-workdir> apropos binfmt Sep 02 11:30:45 binfmt.d (5) - Configure additional binary formats for executables at boot Sep 02 11:30:46 systemd-binfmt (8) - Configure additional binary formats for executables at boot Sep 02 11:30:48 systemd-binfmt.service (8) - Configure additional binary formats for executables at boot Sep 02 11:30:55 * DocScrutinizer05 pukes Sep 02 11:31:27 but yes, it must call a 32bit ld.so for 32bit ELF Sep 02 11:32:49 I'm extremely shy to ship a ld.so binary with flash-it-all.sh Sep 02 11:34:14 just make a tiny chroot Sep 02 11:34:16 much easier Sep 02 11:34:28 and safer Sep 02 11:34:46 so sorry but when your system doesn't even know how to *load* ELF_32bit, my script is out of luck with hacks how to cope with that Sep 02 11:35:30 KotCzarny: that's bullshit, running a chroot on an unknown target system from a shellscript is probably a *very* poor idea Sep 02 11:35:51 I'm sure it can't be that hard to just create an image that includes all the dynamic objects you need. Sep 02 11:36:12 In fact, you could probably do it with cryopid. Sep 02 11:36:14 apparently doc is not that smart as he wants us to believe Sep 02 11:36:24 FU Sep 02 11:36:53 * DocScrutinizer05 fixes his /ignore Sep 02 11:37:18 Actually, cryopid will probably just remap the same files. Sep 02 11:37:39 * Maxdamantus will try soon. Sep 02 11:38:50 Why do not You just switch from Binary-Foo to 0xFFFF? Sep 02 11:39:05 That will make all Hacks needless Sep 02 11:39:21 apic, there is no one-binary to run everywhere Sep 02 11:39:27 Yes Sep 02 11:39:32 That is why You ship the Source Sep 02 11:39:46 If someone has no GCC, well… Sep 02 11:39:52 You have to make _some_ Assumptions Sep 02 11:39:54 bwahaha Sep 02 11:40:50 which is back to the hacks area Sep 02 11:40:56 True Sep 02 11:41:10 If You have a Hacker-Smartphone and are no Hacker… Sep 02 11:43:40 in short, on 32bit os it would run fine (with libusb-compat or -0 installing) on 64bit one has to allow running 32bit binaries Sep 02 11:44:19 Yup Sep 02 11:44:22 Just put that in the WiKi Sep 02 11:44:23 having one old laptop helps with old devices/software Sep 02 11:44:30 *nod* Sep 02 11:45:59 there's nothing to put into the wiki, it already has sufficient info Sep 02 11:48:12 -l Include libraries in the image of the file for a full image. Sep 02 11:48:21 from cryopid, so I guess you could just use that. Sep 02 11:49:19 DocScrutinizer05: Even better ☺ Sep 02 11:56:07 marginally updated lazyflasher to include instructions how to install 32bit support under debian Sep 02 11:56:11 APic: thanks! Sep 02 11:56:22 ☺ Sep 02 12:00:08 * DocScrutinizer05 idly ponders if the script needs a check for current dir content looking like maemo-my-private-workdir, so a new invokation of the download doesn't create it again recursively Sep 02 12:00:39 ~lazyflashing Sep 02 12:00:40 [lazyflashing] http://wiki.maemo.org/Updating_the_tablet_firmware#The_Lazy_Approach Sep 02 12:03:34 Meh, the executable produced by cryopid seems to segfault. Sep 02 12:03:39 0xdeadbeef04c0ffee in ?? () Sep 02 12:06:50 Could be because I'm freezing it while it's in a gdb breakpoint. Sep 02 12:07:39 afaik, gdb works by injecting code into the target's address space. Sep 02 12:08:24 Though wouldn't imagine it would do it while just doing simple break points (particularly, on syscalls) Sep 02 12:18:03 ok, maybe seeya later, messing with cgroups now Sep 02 13:51:44 actually messing with rbind mounts which I messed up Sep 02 13:52:04 umount -R is not always a great idea Sep 02 13:52:23 particularly when you got TWO /dev **** ENDING LOGGING AT Sat Sep 03 02:59:58 2016