diff --git a/CMakeLists.txt b/CMakeLists.txt index 6b2356a..83a66a4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -40,7 +40,6 @@ if(CURL_FOUND) endif(READELF_RESULT_VAR EQUAL 0) endif(CURL_FOUND) -find_package(OAuth REQUIRED) find_package(Jsoncpp REQUIRED) find_package(Htmlcxx REQUIRED) find_package(Tinyxml2 REQUIRED) diff --git a/README.md b/README.md index f35ba06..03c3db9 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,6 @@ This repository contains the code of unofficial [GOG](http://www.gog.com/) downl ## Dependencies * [libcurl](https://curl.haxx.se/libcurl/) >= 7.32.0 -* [liboauth](https://sourceforge.net/projects/liboauth/) * [librhash](https://github.com/rhash/RHash) * [jsoncpp](https://github.com/open-source-parsers/jsoncpp) * [htmlcxx](http://htmlcxx.sourceforge.net/) @@ -24,7 +23,7 @@ This repository contains the code of unofficial [GOG](http://www.gog.com/) downl ### Debian/Ubuntu # apt install build-essential libcurl4-openssl-dev libboost-regex-dev \ - libjsoncpp-dev liboauth-dev librhash-dev libtinyxml2-dev libhtmlcxx-dev \ + libjsoncpp-dev librhash-dev libtinyxml2-dev libhtmlcxx-dev \ libboost-system-dev libboost-filesystem-dev libboost-program-options-dev \ libboost-date-time-dev libboost-iostreams-dev help2man cmake libssl-dev \ pkg-config zlib1g-dev qtwebengine5-dev diff --git a/cmake/FindOAuth.cmake b/cmake/FindOAuth.cmake deleted file mode 100644 index 55dbd63..0000000 --- a/cmake/FindOAuth.cmake +++ /dev/null @@ -1,28 +0,0 @@ -# - Try to find oauth -# -# Once done this will define -# OAuth_FOUND - System has oauth -# OAuth_INCLUDE_DIRS - The oauth include directories -# OAuth_LIBRARIES - The libraries needed to use oauth - -find_package(PkgConfig) -pkg_check_modules(PC_OAUTH REQUIRED oauth) - -find_path(OAUTH_INCLUDE_DIR oauth.h - HINTS ${PC_OAUTH_INCLUDEDIR} - ${PC_OAUTH_INCLUDE_DIRS} - PATH_SUFFIXES oauth - ) - -find_library(OAUTH_LIBRARY NAMES oauth - HINTS ${PC_OAUTH_LIBDIR} - ${PC_OAUTH_LIBRARY_DIRS} - ) - -mark_as_advanced(OAUTH_INCLUDE_DIR OAUTH_LIBRARY) - -if(PC_OAUTH_FOUND) - set(OAuth_FOUND ON) - set(OAuth_INCLUDE_DIRS ${OAUTH_INCLUDE_DIR}) - set(OAuth_LIBRARIES ${OAUTH_LIBRARY}) -endif(PC_OAUTH_FOUND) diff --git a/include/config.h b/include/config.h index fcecf82..acd607e 100644 --- a/include/config.h +++ b/include/config.h @@ -198,12 +198,6 @@ struct CurlConfig long int iLowSpeedTimeoutRate; }; -struct GogAPIConfig -{ - std::string sToken; - std::string sSecret; -}; - class Config { public: @@ -280,8 +274,6 @@ class Config std::string sEmail; std::string sPassword; - GogAPIConfig apiConf; - // Lists Blacklist blacklist; Blacklist ignorelist; diff --git a/main.cpp b/main.cpp index ac12c99..f884706 100644 --- a/main.cpp +++ b/main.cpp @@ -248,11 +248,6 @@ int main(int argc, char *argv[]) ("lowspeed-rate", bpo::value(&Globals::globalConfig.curlConf.iLowSpeedTimeoutRate)->default_value(200), "Set average transfer speed in bytes per second that the transfer should be below during time specified with --lowspeed-timeout for it to be considered too slow and aborted") ("include-hidden-products", bpo::value(&Globals::globalConfig.bIncludeHiddenProducts)->zero_tokens()->default_value(false), "Include games that have been set hidden in account page") ; - // Options read from config file - options_cfg_only.add_options() - ("token", bpo::value(&Globals::globalConfig.apiConf.sToken)->default_value(""), "oauth token") - ("secret", bpo::value(&Globals::globalConfig.apiConf.sSecret)->default_value(""), "oauth secret") - ; options_cli_no_cfg_hidden.add_options() ("login-email", bpo::value(&Globals::globalConfig.sEmail)->default_value(""), "login email") @@ -702,11 +697,6 @@ int main(int argc, char *argv[]) std::ofstream ofs(Globals::globalConfig.sConfigFilePath.c_str()); if (ofs) { - if (!Globals::globalConfig.apiConf.sToken.empty() && !Globals::globalConfig.apiConf.sSecret.empty()) - { - ofs << "token = " << Globals::globalConfig.apiConf.sToken << std::endl; - ofs << "secret = " << Globals::globalConfig.apiConf.sSecret << std::endl; - } ofs.close(); if (!Globals::globalConfig.bRespectUmask) Util::setFilePermissions(Globals::globalConfig.sConfigFilePath, boost::filesystem::owner_read | boost::filesystem::owner_write);