It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
UPDATE: I reworked the patch a bit: http://pastie.org/6093145 (use this instead of the previous one)
On top of the above changes it includes:

* added color to the progress bar and --no-color option (if you think the color should be off by default - you can just reverse and change it to --color instead and just pass that value). Using vt100 codes for color isn't worse than what is used now for clearing the line. To make it more portable - ncurses can be used.
* instead of "light shade" - put space for empty bars again. It looks better.
* added catching the edge condition on resume, where dlnow and dltotal are both 0.0. Before the bar jumped to 100% and after a few moments to real value. I made it jump from 0% - it's less irritating.
Post edited February 08, 2013 by shmerl
LGOGDownloader 1.17
- Merged the patch by shmerl
- shmerl: Switched the rate from calculating it manually to simply getting it from curl_easy_getinfo. Curl happens already to calculate rate by itself.
- shmerl: Introduced Unicode progress bar. Most terminals used these days support Unicode so it makes sense to make it a default. --no-unicode option allows switching ASCII style simple progress bar back.
- shmerl: Moved the config to shared_ptr in order to pass it around (callback needs it).
- shmerl: added color to the progress bar and --no-color option
- shmerl: added catching the edge condition on resume, where dlnow and dltotal are both 0.0. Before the bar jumped to 100% and after a few moments to real value. I made it jump from 0% - it's less irritating
- shmerl: Had to use a workaround to detect the case of (dlnow == 0.0) && (dltotal == 389.0) otherwise the progress bar will be missing the very last small part.
- Incomplete cover downloads are resumed
- Added __LP64__ to environment detection

http://sites.google.com/site/gogdownloader/lgogdownloader-1.17.tar.gz

No checks are made for the covers to ensure that it's the same file when resuming. It's possible to "resume" complete file if the file to be downloaded is bigger. This shouldn't happen unless I've changed cover image in the *.xml for some reason
I'm on Linux Mint 13 and when I try to add that PPA it works, but I get the following errors when I run apt-get update:

W: Failed to fetch http://ppa.launchpad.net/gabriel-thornblad/lgogdownloader/ubuntu/dists/precise/main/source/Sources 404 Not Found

W: Failed to fetch http://ppa.launchpad.net/gabriel-thornblad/lgogdownloader/ubuntu/dists/precise/main/binary-i386/Packages 404 Not Found

I also tried to compile from source, but a couple of the required packages (liboauth-dev and libcurl4-openssl-dev) have conflicting dependencies which I haven't been able to resolve.

Now tried to install the .deb, but I get the message: Error: Dependency is not satisfiable: libboost-filesystem1.49.0 (>= 1.49.0-1).

The latest version of libboost-filesystem available as far as I see is 1.48.
Post edited February 12, 2013 by Nerritti
avatar
Nerritti: I'm on Linux Mint 13 and when I try to add that PPA it works, but I get the following errors when I run apt-get update:

W: Failed to fetch http://ppa.launchpad.net/gabriel-thornblad/lgogdownloader/ubuntu/dists/precise/main/source/Sources 404 Not Found

W: Failed to fetch http://ppa.launchpad.net/gabriel-thornblad/lgogdownloader/ubuntu/dists/precise/main/binary-i386/Packages 404 Not Found

I also tried to compile from source, but a couple of the required packages (liboauth-dev and libcurl4-openssl-dev) have conflicting dependencies which I haven't been able to resolve.

Now tried to install the .deb, but I get the message: Error: Dependency is not satisfiable: libboost-filesystem1.49.0 (>= 1.49.0-1).

The latest version of libboost-filesystem available as far as I see is 1.48.
Yes, the deb that I have packaged is for Ubuntu 12.10 (Quantal) and its derivations only - sorry about that. If I magically found some of my lost spare time I could set it up for other versions as well, but don't hold your breath.
It builds just fine for me on Debian testing though (except for the hash include change). I guess it should also work with Mint LMDE.
Post edited February 12, 2013 by shmerl
avatar
Nerritti: I also tried to compile from source, but a couple of the required packages (liboauth-dev and libcurl4-openssl-dev) have conflicting dependencies which I haven't been able to resolve.
I'm guessing liboauth-dev depends on libcurl4-gnutls-dev? It should build and work with libcurl4-gnutls-dev when rhash include path is changed to <rhash.h> (or at least it worked the last time I built it using Debian few months ago)

LGOGDownloader 1.18
- Use HTTP::getFreeGames() to get the list of free games instead of using hardcoded list of free games

http://sites.google.com/site/gogdownloader/lgogdownloader-1.18.tar.gz

edit: accidentally included some temporary files in the *.tar.gz
replaced it with fixed *.tar.gz
md5: 5d27de7abb8ccbc9de76d475b6814f05
sha256: f94b72693f716c461ea04d9427fc3f65bfedf7e1683767f379eb4dbd6eb18346
Post edited February 12, 2013 by Sude
just compiled ver1.18 and it all works fine :)

however going through my collection i see that some of the covers are corrupt, i deleted them and tried to download them again but still the file sizes are too small, on the order of 168kb to around 350 kb

the covers that are corrupt (as in no program will open them) are
teenagent
syberia2
syberia
outcast
fallout tactics
fallout 2
bloodrayne2
bloodrayne

during the download every faulty cover stops at 50% as in the following:

Downloading cover /data/common_stuff/file_store/games/goodoldgames/teenagent/cover_0.png
50% ▕█████████████ ▏ 0.00/0.00MB @ 0.00kB/s ETA: 24855d 03h 14m 08s


trying --verbose for just teenagent give the following:

$ lgogdownloader --verbose --download --game teenagent --directory /data/common_stuff/file_store/games/goodoldgames/ --create-xml automatic --xml-directory /data/common_stuff/lgogdownloader/xml/
Getting game info 1 / 1
Downloading cover /data/common_stuff/file_store/games/goodoldgames/teenagent/cover_0.png
* About to connect() to img232.imageshack.us port 80 (#2)
* Trying 208.94.0.172...
* connected ▏ 0.00/0.00MB @ 0.00kB/s ETA: 24855d 03h 14m 08s
* Connected to img232.imageshack.us (208.94.0.172) port 80 (#2)
> GET /img232/5814/Teenagent.png HTTP/1.1
Range: bytes=168-
User-Agent: GOGDownloader for Linux
Host: img232.imageshack.us
Accept: */*

< HTTP/1.1 404 Not Found

which seems to say that the file doesn't exist even though there is an attempt to download it!

diziet
imageshack is not a reliable storage - they regularly lose data, and restore it only by request (try reporting the missing image to them through https://imageshack.us/content.php?page=email&amp;q=customer ). I thought covers are coming from GOG, but if not - there is no guarantee that they still exist. The downloader naturally needs to catch that condition and report it, instead of quietly saying 50%.
Post edited February 14, 2013 by shmerl
avatar
diziet_sma: just compiled ver1.18 and it all works fine :)

however going through my collection i see that some of the covers are corrupt, i deleted them and tried to download them again but still the file sizes are too small, on the order of 168kb to around 350 kb

the covers that are corrupt (as in no program will open them) are
teenagent
syberia2
syberia
outcast
fallout tactics
fallout 2
bloodrayne2
bloodrayne
There's a problem with imageshack.
Tried downloading "teenagent" cover with the downloader and it fails (error code 404). Downloading it with wget works fine.
I'll upload those images to another filehost.
edit: it's actually case-sensitivity problem, imageshack urls should be all lowercase but some links in the cover list have capitals in them. I think this can be easily fixed with some regex. I'll update the cover list when I've managed to fix the links
edit2: cover list should be fixed now

avatar
shmerl: I thought covers are coming from GOG, but if not - there is no guarantee that they still exist.
The covers are hosted on number of different filehosts. I just take the cover links from here and add them to the cover list.
http://sites.google.com/site/gogdownloader/GOG_covers.xml

It would be best to host them somewhere reliable but it means downloading all covers, uploading them and updating the cover list. I haven't had the time to do that.

LGOGDownloader 1.19
- Check for HTTP errors when downloading covers
- Fixed template for curlhandle::get_info(). Templates can't be split between *.h and *.cpp
- downloadFile() now returns CURLcode instead of int. Default code is CURLE_RECV_ERROR (Failure with receiving network data)

http://sites.google.com/site/gogdownloader/lgogdownloader-1.19.tar.gz

sha256: 2aae7897f12fa67159d46d1cf44b0c034fedb9817094c17ed0829dc02f18f1dd
md5: 0b2894f7f0f9c6400bc51bcea068026d
Post edited February 15, 2013 by Sude
Sude, thanks for this amazing program. It's awesome and so is the person maintaining the ppa for Ubuntu.
avatar
silviucc: Sude, thanks for this amazing program. It's awesome and so is the person maintaining the ppa for Ubuntu.
Do they plan to put it in normal Debian repos as well?
Post edited February 24, 2013 by shmerl
avatar
silviucc: Sude, thanks for this amazing program. It's awesome and so is the person maintaining the ppa for Ubuntu.
avatar
shmerl: Do they plan to put it in normal Debian repos as well?
I don't really have an idea but it seems it's being developed on debian at least and the compile instructions seem debian centric. You should probably be able to make your own package.

https://sites.google.com/site/gogdownloader/home
@silviucc: So far I built it manually, but I'll take a look at how to create a Debian package. Debian testing has some differences (like in rhash include) because it's a bit stalled at the moment (release freeze). Is the Unicode progress bar working well for you by the way? I didn't really get any feedback on that, and I hope it's OK.
Post edited February 24, 2013 by shmerl
LGOGDownloader 1.20
- Update progress bar every 100ms instead of every time progress_callback gets called. This prevents the progress bar from flickering because of too fast updates.

http://sites.google.com/site/gogdownloader/lgogdownloader-1.20.tar.gz

sha256: 4607521114edb5be30ae0d76e7e565313208273a340fe509c13743ff5edf251f
md5: eb11e4d277a1d92256b8984e645637f9
Doesn't compile under Debian 6.0.6 because there is no package "librhash-dev" available....

Can you provide a 32 bit statical linked intel binary or include the rhash library for systems which are not Ubuntu?

-- compilation dump after starting makefile --
test -d bin/Debug || mkdir -p bin/Debug
test -d obj/Debug || mkdir -p obj/Debug
test -d obj/Debug/src || mkdir -p obj/Debug/src
g++ -std=c++0x -Wall -fexceptions -g -DDEBUG -Iinclude -c main.cpp -o obj/Debug/main.o
In file included from include/http.h:11,
from main.cpp:10:
include/util.h:16:19: error: rhash.h: No such file or directory
In file included from include/api.h:10,
from main.cpp:7:
include/curlhandle.h:41: error: ‘nullptr’ was not declared in this scope
main.cpp: In function ‘int repairFile(curlhandle*, std::string, std::string, std::string, std::string)’:
main.cpp:135: error: ‘struct std::basic_string<char, std::char_traits<char>, std::allocator<char> >’ has no member named ‘string’
main.cpp:237: error: ‘RHASH_MD5’ was not declared in this scope
main.cpp: In function ‘int createXML(std::string, size_t, std::string)’:
main.cpp:391: error: ‘struct std::basic_string<char, std::char_traits<char>, std::allocator<char> >’ has no member named ‘string’
main.cpp:402: error: ‘RHASH_MD5’ was not declared in this scope
main.cpp: In function ‘int updateGames(API*, std::shared_ptr<Config>, std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >)’:
main.cpp:544: error: no matching function for call to ‘rename(boost::filesystem::path&, boost::filesystem::path&, boost::system::error_code&)’
/usr/include/boost/filesystem/operations.hpp:737: note: candidates are: void boost::filesystem::rename(const boost::filesystem::path&, const boost::filesystem::path&)
/usr/include/boost/filesystem/operations.hpp:739: note: void boost::filesystem::rename(const boost::filesystem::wpath&, const boost::filesystem::wpath&)
main.cpp:597: error: no matching function for call to ‘rename(boost::filesystem::path&, boost::filesystem::path&, boost::system::error_code&)’
/usr/include/boost/filesystem/operations.hpp:737: note: candidates are: void boost::filesystem::rename(const boost::filesystem::path&, const boost::filesystem::path&)
/usr/include/boost/filesystem/operations.hpp:739: note: void boost::filesystem::rename(const boost::filesystem::wpath&, const boost::filesystem::wpath&)
make: *** [obj/Debug/main.o] Error 1
--- compilation dump ends ---