I can’t get the new Linux 0.2.2 to run. Has anyone else managed to do it? Using the instructions given at literatureandlatte.com/wiki/doku … r_in_Linux I get “error while loading shared libraries: /usr/local/LiteratureAndLatte/lib/libQtWebKit.so.4: file too short” when using the command sudo ldd /usr/local/LiteratureAndLatte/bin/Scrivener
Yeah known issue. I think Lee messed up linking libs when compiling it. Or they didn’t preserve the simlinks on the libs. I’m not awake enough to try linking them by hand.
Actually it does work. I know ownership is messed up, but I forgot to sudo when linking. I’ll chown everything correctly in a bit. I just wanted to verify that it’ll work. This is how things should be linked up. ln -sf is your friend. (Worst case if you screw up, just delete the entire file and unpack it again.
% /usr/local/LiteratureAndLatte/lib ls -lh hildegard@volmar
total 40M
-rwxrwxrwx 1 root 707 2011-04-08 17:44 libQtCore.la
-rwxrwxrwx 1 root 798 2011-04-08 17:44 libQtCore.prl
lrwxrwxrwx 1 hildegard 18 2011-04-09 12:36 libQtCore.so -> libQtCore.so.4.7.0
lrwxrwxrwx 1 hildegard 18 2011-04-09 12:36 libQtCore.so.4 -> libQtCore.so.4.7.0
lrwxrwxrwx 1 hildegard 18 2011-04-09 12:37 libQtCore.so.4.7 -> libQtCore.so.4.7.0
-rwxrwxrwx 1 root 2.7M 2011-04-08 17:44 libQtCore.so.4.7.0
-rwxrwxrwx 1 root 762 2011-04-08 17:44 libQtGui.la
-rwxrwxrwx 1 root 879 2011-04-08 17:44 libQtGui.prl
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:37 libQtGui.so -> libQtGui.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:37 libQtGui.so.4 -> libQtGui.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:37 libQtGui.so.4.7 -> libQtGui.so.4.7.0
-rwxrwxrwx 1 root 12M 2011-04-08 17:44 libQtGui.so.4.7.0
-rwxrwxrwx 1 root 819 2011-04-08 17:44 libQtMultimedia.la
-rwxrwxrwx 1 root 882 2011-04-08 17:44 libQtMultimedia.prl
lrwxrwxrwx 1 hildegard 24 2011-04-09 12:38 libQtMultimedia.so -> libQtMultimedia.so.4.7.0
lrwxrwxrwx 1 hildegard 24 2011-04-09 12:38 libQtMultimedia.so.4 -> libQtMultimedia.so.4.7.0
lrwxrwxrwx 1 hildegard 24 2011-04-09 12:38 libQtMultimedia.so.4.7 -> libQtMultimedia.so.4.7.0
-rwxrwxrwx 1 root 110K 2011-04-08 17:44 libQtMultimedia.so.4.7.0
-rwxrwxrwx 1 root 773 2011-04-08 17:44 libQtNetwork.la
-rwxrwxrwx 1 root 846 2011-04-08 17:44 libQtNetwork.prl
lrwxrwxrwx 1 hildegard 21 2011-04-09 12:39 libQtNetwork.so -> libQtNetwork.so.4.7.0
lrwxrwxrwx 1 hildegard 21 2011-04-09 12:39 libQtNetwork.so.4 -> libQtNetwork.so.4.7.0
lrwxrwxrwx 1 hildegard 21 2011-04-09 12:39 libQtNetwork.so.4.7 -> libQtNetwork.so.4.7.0
-rwxrwxrwx 1 root 1002K 2011-04-08 17:44 libQtNetwork.so.4.7.0
-rwxrwxrwx 1 root 745 2011-04-08 17:44 libQtSql.la
-rwxrwxrwx 1 root 830 2011-04-08 17:44 libQtSql.prl
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:40 libQtSql.so -> libQtSql.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:40 libQtSql.so.4 -> libQtSql.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:40 libQtSql.so.4.7 -> libQtSql.so.4.7.0
-rwxrwxrwx 1 root 710K 2011-04-08 17:44 libQtSql.so.4.7.0
-rwxrwxrwx 1 root 770 2011-04-08 17:44 libQtSvg.la
-rwxrwxrwx 1 root 854 2011-04-08 17:44 libQtSvg.prl
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:40 libQtSvg.so -> libQtSvg.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:40 libQtSvg.so.4 -> libQtSvg.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:40 libQtSvg.so.4.7 -> libQtSvg.so.4.7.0
-rwxrwxrwx 1 root 356K 2011-04-08 17:44 libQtSvg.so.4.7.0
-rwxrwxrwx 1 root 876 2011-04-08 17:44 libQtWebKit.la
-rwxrwxrwx 1 root 856 2011-04-08 17:44 libQtWebKit.prl
-rwxrwxrwx 1 root 20 2011-04-08 18:01 libQtWebKit.so
lrwxrwxrwx 1 hildegard 20 2011-04-09 12:41 libQtWebKit.so.4 -> libQtWebKit.so.4.7.0
lrwxrwxrwx 1 hildegard 20 2011-04-09 12:41 libQtWebKit.so.4.7 -> libQtWebKit.so.4.7.0
-rwxrwxrwx 1 root 19M 2011-04-08 17:44 libQtWebKit.so.4.7.0
-rwxrwxrwx 1 root 745 2011-04-08 17:44 libQtXml.la
-rwxrwxrwx 1 root 829 2011-04-08 17:44 libQtXml.prl
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:41 libQtXml.so -> libQtXml.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:42 libQtXml.so.4 -> libQtXml.so.4.7.0
lrwxrwxrwx 1 hildegard 17 2011-04-09 12:42 libQtXml.so.4.7 -> libQtXml.so.4.7.0
-rwxrwxrwx 1 root 275K 2011-04-08 17:44 libQtXml.so.4.7.0
-rwxrwxrwx 1 root 813 2011-04-08 17:44 libQtXmlPatterns.la
-rwxrwxrwx 1 root 874 2011-04-08 17:44 libQtXmlPatterns.prl
lrwxrwxrwx 1 hildegard 25 2011-04-09 12:42 libQtXmlPatterns.so -> libQtXmlPatterns.so.4.7.0
lrwxrwxrwx 1 hildegard 25 2011-04-09 12:43 libQtXmlPatterns.so.4 -> libQtXmlPatterns.so.4.7.0
lrwxrwxrwx 1 hildegard 25 2011-04-09 12:43 libQtXmlPatterns.so.4.7 -> libQtXmlPatterns.so.4.7.0
-rwxrwxrwx 1 root 4.2M 2011-04-08 17:44 libQtXmlPatterns.so.4.7.0
-rwxrwxrwx 1 root 777 2011-04-08 17:44 libphonon.la
-rwxrwxrwx 1 root 877 2011-04-08 17:44 libphonon.prl
lrwxrwxrwx 1 hildegard 18 2011-04-09 12:43 libphonon.so -> libphonon.so.4.4.0
lrwxrwxrwx 1 hildegard 18 2011-04-09 12:43 libphonon.so.4 -> libphonon.so.4.4.0
lrwxrwxrwx 1 hildegard 18 2011-04-09 12:43 libphonon.so.4.4 -> libphonon.so.4.4.0
-rwxrwxrwx 1 root 340K 2011-04-08 17:44 libphonon.so.4.4.0
Thanks for the reply. I’m afraid I still can’t get it to work, I’m not a Linux guru. I’ve got the LiteratureAndLatte folder in usr/local. What do I need to do next? Thanks again for your help.
This assumes you’re familiar and comfortable with basic shell commands like cd, ls, sudo.
Go into the lib directory of the new version. See how there are a bunch of similar things with different extensions? The libraries in question are those ending in .so, so.4, and so.4.7. Those must be linked with the version ending in *.4.7.0 (except in the case of libphonon.) Normally when you compile a binary, those links are made automatically–since it was the libraries used to build the binary. If any of those links are missing, then they need to be made.
In linux, if it starts with “lib” it’s a good guess that it’s a library file.
This is a good thing to know how to do in a system admin kind of way, since simlinks get broken all the time, and it’s an easy thing you can do to fix it.
First read about the ln command: linux.about.com/od/commands/l/blcmdl1_ln.htm
Secondly, you need sudo access.
See the list I posted further up in this thread? Everything that has an arrow is what’s going to become a link. The right side of the arrow is what the link points to. That’s the target file.
So if you have a target file of foo, and you’d like to link it to bar, you’d do:
touch foo (it’ll create a file named foo)
ln -s foo bar
if you’d do ls -lh bar, you’d see bar -> foo.
Play around with this in your home directory until you have a good feel for the command. Note the option given to ln. It won’t let you overwrite something that’s already there. But when we get to linking the Scrivener libraries, we’ll need to. (So tread carefully when you actually go to do it, because you can overwrite the original with a useless link, if you aren’t careful. If that happens, just unpack the file and start over. Or keep another version of Scrivener unzipped somewhere, so you can copy over the library you accidentally overwrote.)
This next step assumes you’ve got the 2.2 beta unzipped where it needs to be. pull up some sort of file manager so you can see exactly what you’ve got in there. You’ll also need that list I posted before in this thread. That shows the correct linkings. Everywhere you see an arrow, you’ll have to do ln -sf (will force it over the file, so be careful…it’ll overwrite the existing file.) to create the link. Make sure you sudo or are working as root.
Standard disclaimer: with great power comes great responsibility, especially when using root or sudo. Make certain you’re ONLY messing with libraries in /usr/local/LiteratureAndLatte/lib.
Note you should be in /usr/local/LiteratureAndLatte/lib. Good luck! It’s really not as hard as you think. up arrow will bring up the last command you gave in a shell, so that should save you some time. (As will vi bindings, if you’re comfortable with that and your shell supports it.)
I went through and linked them all manually and after running ldd it starts up no problem. In fact it’s incredibly fast, under a second.
What version is yours reporting? I’m seeing version 019, yet this is a manual install and I rm -rf’d the previous.
Yeah it’s 022. It says 019 in the about Scrivener box, but it’s got the same bugs as the 2.2 version does.
Hey garpu, I tried to follow your instructions to manually link the lib files in your list and no matter what I do, only some of the files show as linked when I do ls -lh (I also still get the “file too short” error when I try to run ldd). I am not a Linux expert by any means, so chances are I’m just doing something wrong. To confirm, I should be cd’ing to the /usr/local/LiteratureAndLatte/lib folder, then doing sudo ln -sf libQtCore.so libQtCore.so.4.7.0
sudo ln -sf libQtCore.so.4 libQtCore.so.4.7.0
sudo ln -sf libQtCore.so.4.7 libQtCore.so.4.7.0
and so on with all the linked files in your list?
Thank you so much for your help garpu. It is now up and running after following your instructions.
sprat, following garpu’s instructions, I think you need to link all the libraries to get itworking rather than just three as you have. Try the code below, it worked for me.
ln -sf libQtCore.so.4.7.0 libQtCore.so
ln -sf libQtCore.so.4.7.0 libQtCore.so.4
ln -sf libQtCore.so.4.7.0 libQtCore.so.4.7
ln -sf libQtGui.so.4.7.0 libQtGui.so
ln -sf libQtGui.so.4.7.0 libQtGui.so.4
ln -sf libQtGui.so.4.7.0 libQtGui.so.4.7
ln -sf libQtMultimedia.so.4.7.0 libQtMultimedia.so
ln -sf libQtMultimedia.so.4.7.0libQtMultimedia.so.4
ln -sf libQtMultimedia.so.4.7.0 libQtMultimedia.so.4.7
ln -sf libQtNetwork.so.4.7.0 libQtNetwork.so
ln -sf libQtNetwork.so.4.7.0 libQtNetwork.so.4
ln -sf libQtNetwork.so.4.7.0 libQtNetwork.so.4.7
ln -sf libQtSql.so.4.7.0 libQtSql.so
ln -sf libQtSql.so.4.7.0 libQtSql.so.4
ln -sf libQtSql.so.4.7.0 libQtSql.so.4.7
ln -sf libQtSvg.so.4.7.0 libQtSvg.so
ln -sf libQtSvg.so.4.7.0 libQtSvg.so.4
ln -sf libQtSvg.so.4.7.0 libQtSvg.so.4.7
ln -sf libQtWebKit.so.4.7.0 libQtWebKit.so.4
ln -sf libQtWebKit.so.4.7.0 libQtWebKit.so.4.7
ln -sf libQtXml.so.4.7.0 libQtXml.so
ln -sf libQtXml.so.4.7.0 libQtXml.so.4
ln -sf libQtXml.so.4.7.0 libQtXml.so.4.7
ln -sf libQtXmlPatterns.so.4.7.0 libQtXmlPatterns.so
ln -sf libQtXmlPatterns.so.4.7.0 libQtXmlPatterns.so.4
ln -sf libQtXmlPatterns.so.4.7.0 libQtXmlPatterns.so.4.7
ln -sf libphonon.so.4.4.0 libphonon.so
ln -sf libphonon.so.4.4.0 libphonon.so.4
ln -sf libphonon.so.4.4.0 libphonon.so.4.4
No problem!
Common error, sprat. you’re linking the bad file to the good one. You’ll have to unpack it and start over.
Ah, that makes sense! Thanks so much to you both – I’ll give that a shot.
ETA: And success!! Awesome. Much appreciate the help.
No prob! That’s a really easy mistake to make. Better to do it here than on something that matters.
Am stuck at the same step. “libQtWebKit.so.4 to long” thing,
tried to follow Garpu’s instructions, thanks very much but didn’t dare since i didnt understand it. So I’m hoping that once a .deb is available, that will overwrite and fix everything? Or do i have to delete the usr/local/LiteratureAndLatte thing again.
although the .deb file of the March 24th version, hasnt been working on my computer, as soon as i typed something it just crashed, so i had to dig up the pre-march 25th and change the time preferences every time. This March 25th one was the first robhamm .deb package i used, with randywallace everything went mighty fine.
Standard disclaimer. I’m not really a programmer. I do stuff in functional languages (csound, LISP), but I understand binaries/libraries only as much as I need to for a linuxy sysadmin type of thing.
Programs are binaries. They can either be statically or dynamically compiled. You’ve got a bunch of statically compiled binaries already in /sbin (or they SHOULD) be. This means that the library information (that is, stuff programs need to know in order t run) is compiled into the binary and it’s stand alone. This is important, because if something goes wrong in /lib, your vital system commands would disappear. Without the statically compiled stuff in /sbin, you’d be up a proverbial creek. Those binaries, though, are huge in comparison.
Dynamically compiled binaries need to link (or look up stuff) in other libraries in order to work. They’re smaller, which is why most software is dynamically compiled.
In Scrivener’s case, it’s using some that are on your system (glibc, for instance) and some that it provides (everything in LiteratureAndLatte/lib). The ones it provides are the ones that have been heavily customized for the program. (Which is why if you try loading Scrivener with your system Qt libraries, it won’t work.)
Normally in the installation phase, libraries used to compile the binary are linked. (If you’ve ever installed software from source, you’ve seen the prompt to run ldconfig after installing? It’s prompting you to re-link certain libraries installed with the new software–most install scripts these days do it automatically.)
So something happened in the packaging of the current linux build of Scrivener (I’m guessing) where the libraries weren’t linked. I’m sure there’s a way to write a script to link them, but it would’ve taken me as long to shell script it than to do it by hand.
ln is a command that will link things. (binaries, files, anything.) Any time you do an ls to look at a directory’s contents and see a little arrow “->”, it’s been linked.
The manpage says ln target object, so if you do ln -s foo bar, you’ll link bar to foo. That’s all it does.
The manual procedure worked for me. I just want to thank garpu for taking the time to post and having the expertise to know what to do. Heck, thanks to all of the people who are helping bring the Scrivener betas to Linux.
Anyone have luck getting the 2.2 spell checker to work properly on 64 bit systems?
(he asked hopefully)
WIKID, i tried it and it worked, although the instructions too unexplicit for me.
for all the beginners there, what they mean is
first Unzip the downloaded file and move it to the usr/local ( I follwed these steps here: http://www.omgubuntu.co.uk/2011/03/scrivener-for-linux-gets-official-beta-release/
Installing Scrivener Beta 1.7 in Linux
Download the package above and un-tar. (Right click > ‘Extract here’).
Press ALT + F2 and type ‘gksu nautilus’
In the file browser that opens Navigate to ‘File System > usr > local’
Move the extracted folder, called ‘LiterarureAndLatte’, to this location
Then in a Terminal
- cd /usr/local/LiteratureAndLatte/lib
- then follow the code provided in previous post (i did it without typing sudo and it worked): "Try the code below, it worked for me.
ln -sf libQtCore.so.4.7.0 libQtCore.so
ln -sf libQtCore.so.4.7.0 libQtCore.so.4
ln -sf libQtCore.so.4.7.0 libQtCore.so.4.7
ln -sf libQtGui.so.4.7.0 libQtGui.so
ln -sf libQtGui.so.4.7.0 libQtGui.so.4
ln -sf libQtGui.so.4.7.0 libQtGui.so.4.7
ln -sf libQtMultimedia.so.4.7.0 libQtMultimedia.so
ln -sf libQtMultimedia.so.4.7.0libQtMultimedia.so.4
ln -sf libQtMultimedia.so.4.7.0 libQtMultimedia.so.4.7
ln -sf libQtNetwork.so.4.7.0 libQtNetwork.so
ln -sf libQtNetwork.so.4.7.0 libQtNetwork.so.4
ln -sf libQtNetwork.so.4.7.0 libQtNetwork.so.4.7
ln -sf libQtSql.so.4.7.0 libQtSql.so
ln -sf libQtSql.so.4.7.0 libQtSql.so.4
ln -sf libQtSql.so.4.7.0 libQtSql.so.4.7
ln -sf libQtSvg.so.4.7.0 libQtSvg.so
ln -sf libQtSvg.so.4.7.0 libQtSvg.so.4
ln -sf libQtSvg.so.4.7.0 libQtSvg.so.4.7
ln -sf libQtWebKit.so.4.7.0 libQtWebKit.so.4
ln -sf libQtWebKit.so.4.7.0 libQtWebKit.so.4.7
ln -sf libQtXml.so.4.7.0 libQtXml.so
ln -sf libQtXml.so.4.7.0 libQtXml.so.4
ln -sf libQtXml.so.4.7.0 libQtXml.so.4.7
ln -sf libQtXmlPatterns.so.4.7.0 libQtXmlPatterns.so
ln -sf libQtXmlPatterns.so.4.7.0 libQtXmlPatterns.so.4
ln -sf libQtXmlPatterns.so.4.7.0 libQtXmlPatterns.so.4.7
ln -sf libphonon.so.4.4.0 libphonon.so
ln -sf libphonon.so.4.4.0 libphonon.so.4
ln -sf libphonon.so.4.4.0 libphonon.so.4.4
[/quote]
Then the remiaing steps of the http://literatureandlatte.com/wiki/doku.php?id=Running_Scrivener_in_Linux
sudo ldd /usr/local/LiteratureAndLatte/bin/Scrivener
sudo chmod 755 /usr/local/LiteratureAndLatte/bin/Scrivener
Thanks garpu and the forum!, i read it 15 times before i tried it.
I got mine working as well. Thanks guys and gals. One thing I did notice though is that mine doesn’t pop up with the notice saying when the beta will expire. Is this normal for this version?
I didn’t get that, either. I’m assuming it’s moot for the linux version for now.