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

×
avatar
coffeecup: ...
There are also errors because of too old gcc/g++ and libboost-filesystem. Getting it to build on Debian stable would require rewriting some of the code to get rid of all the C++11 features that are used.

WARNING
Following these instructions will install lots of packages from testing. Some of them can cause some serious problems when other packages aren't updated at the same time. Among the installed packages are kernel and libc, so the potential for possible disaster is high.

Add testing to /etc/apt/sources.list
Pin testing to -1 in /etc/apt/preferences

Package: *
Pin: release a=testing
Pin-Priority: -1
sudo apt-get update
sudo apt-get install -t testing librhash-dev libhtmlcxx-dev libjsoncpp-dev libboost-filesystem-dev g++-4.6

wget http://sites.google.com/site/gogdownloader/lgogdownloader-1.20.tar.gz
tar -xvzf lgogdownloader-1.20.tar.gz
cd lgogdownloader-1.20
sed -e "s;rhash.h;rhash/rhash.h;" -i *.cpp */*.cpp */*.h
sed -e "s;gcc;gcc-4.6;g" -e "s;g++;g++-4.6;g" -i Makefile
make release
sudo make install
Thank you for the hints, though they were a bit unclear, especially what you meant with "Pin testing".

After moving to debian testing (replace squeeze with testing in /etc/sources.list) and
-> su -
-> apt-get update
-> apt-get install -t testing librhash-dev libhtmlcxx-dev libjsoncpp-dev libboost-filesystem-dev g++-4.6

(don't use sudo, it has a big security problem: set system time to 0 and every user can be root (http://www.sudo.ws/sudo/alerts/epoch_ticket.html))

-> exit
-> wget http://sites.google.com/site/gogdownloader/lgogdownloader-1.20.tar.gz
-> tar -xvzf lgogdownloader-1.20.tar.gz
-> cd lgogdownloader-1.20
-> sed -e "s;rhash.h;rhash/rhash.h;" -i *.cpp */*.cpp */*.h
-> sed -e "s;gcc;gcc-4.6;g" -e "s;g++;g++-4.6;g" -i Makefile
-> make release

This gives an error, missing libboost-date-time

-> su -
-> apt-get install libboost-date-time1.49dev
-> exit
-> make

This gives a binary in bin/Release/ called lgogdownloader, which seems to work.

Thanks :)
Hi,

I have just installed your program on Arch Linux from source and it works well.

At first, I have installed the dependencies listed here: https://aur.archlinux.org/packages/lgogdownloader/ , then I followed the instructions of your first post.

I had a 'Permission denied' error:
lgogdownloader: error while loading shared libraries: libjsoncpp.so: cannot open shared object file: Permission denied

...solved by the following command:
$ sudo chmod a+r /usr/lib/libjson_linux-gcc-4.7.2_libmt.so

Thanks a lot for this great software.
LGOGDownloader 2.0
- Major code restructuring
- Removed curlhandle class, use curl_easy interface directly
- Moved most of the code to new Downloader class
- createXML() moved to Util namespace
- Removed HTTP namespace and moved all functionality to Downloader class
- API::getGameDetails() now has a parameter "const unsigned int& type" that allows to select which installers are downloaded (1=Windows, 2=Mac, 3=Both)
- Added --platform option to select which installers are downloaded (Default: 1, download only Windows installers)

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

sha256: 9616b594816cfafbfc1b9add1258f98efc2d74d45392f19af0fe38372b9d739e
md5: df9fa77f30757be60a7ef7dff690e096
Trying to compile v2.0 on Xubuntu 12.10 but getting the following error:

tiberious@raggamuffin:~/Downloads/lgogdownloader-2.0$ make release
test -d bin/Release || mkdir -p bin/Release
test -d obj/Release || mkdir -p obj/Release
test -d obj/Release/src || mkdir -p obj/Release/src
g++ -std=c++0x -Wall -fexceptions -O2 -Iinclude -c main.cpp -o obj/Release/main.o
In file included from main.cpp:9:0:
include/util.h:16:19: fatal error: rhash.h: No such file or directory
compilation terminated.
make: *** [obj/Release/main.o] Error 1

I definitely have librhash-dev installed so I'm not sure if I've missed something else.

EDIT: OK it was a hack but I fixed the issue by symlinking /usr/include/rhash/rhash.h into the include folder of the lgogdownloader source. I'm really not sure why I had to do that but it appears to have fixed the compile error.
Post edited March 07, 2013 by slackthumbz
ignore this post I was being an idiot and didn't read the options properly.
Post edited March 07, 2013 by slackthumbz
avatar
slackthumbz: EDIT: OK it was a hack but I fixed the issue by symlinking /usr/include/rhash/rhash.h into the include folder of the lgogdownloader source. I'm really not sure why I had to do that but it appears to have fixed the compile error.
I'm using Arch Linux which has rhash 1.2.10 in AUR. In 1.2.10 the include path for rhash is changed from rhash/rhash.h to rhash.h. Ubuntu and Debian (testing/unstable) has rhash 1.2.9 in their repositories.
Debian and Ubuntu users need to change the include path in "lgogdownloader/include/util.h"
sed -e "s;rhash.h;rhash/rhash.h;" -i include/util.h

I probably should add this to the compile instructions in the first post.
Post edited March 08, 2013 by Sude
This works beautifully, Linux Mint 14.

Thanks so much!
avatar
Sude: Some documentation that I wrote for the GOG API
GOG API Documentation
Very interesting read. Thanks for the info.
GOG made some changes to the API and this broke the downloader

I'm waiting for a response to this
https://secure.gog.com/forum/general/introducing_the_beta_release_of_the_new_gogcom_downloader/post1459
before I release a new version that works
LGOGDownloader 2.1
- Use defined constant INSTALLER_WINDOWS to set the default value for "type" in API::getGameDetails()
- Report HTTP errors in API
- error and error_message are now private members in API
- Added API::setError(), API::getError() and API::getErrorMessage() methods
- Implemented language selection for installers. Use "--language" to select the language
- API::getGameDetails() now has a parameter "const unsigned int& lang" that allows to select which language installers are downloaded (bitmask is used for selection)
- Current selectable languages are English (1), German (2), French (4), Polish (8) and Russian (16).
Add the values to download multiple languages. For example: 1+2+4+8+16=31 = all languages and 4+8=12 = French & Polish

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

sha256: 60325c31577441998fb659a9c9e6a9457b614c468c838ba3fa521134cae07819
md5: 7f6827ec466fd2a180a93dc8322b29ac

GOG also added updated flag to the API for installers. This will be useful later for automatic updates.
Post edited March 11, 2013 by Sude
Is there a public repository of the sourcecode anywhere?
I think it would be good to put the project on Github or Google Code for easier access, bug tracking and so on.
avatar
shmerl: I think it would be good to put the project on Github or Google Code for easier access, bug tracking and so on.
You are right. In my opinion, GitHub would be the best solution =)

It is much easier to use git and there are issues, milestones, wikis and much more features on GitHub =)
Post edited March 12, 2013 by Daniel Ruf
LGOGDownloader 2.2
- Changed the cover XML data format: accurate cover matching from the cover xml data by using gamename instead of gametitle.
- Cover list is only downloaded when using --download

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

sha256: 02ed22850915e42c3329a4216e2c1e09af2939e48ef036d915e53230f135050c
md5: d920e2f4ad22c37ebc0b99992367777b

The new cover list be found here

I'll see about setting up a code repository. Which would you prefer Google Code, GitHub or something else?