diff options
-rw-r--r-- | build/common.gypi | 2 | ||||
-rw-r--r-- | chrome/chrome.gyp | 22 | ||||
-rw-r--r-- | chrome/service/cloud_print/print_system_cups.cc | 1 | ||||
-rw-r--r-- | printing/backend/print_backend_cups.cc | 6 | ||||
-rw-r--r-- | printing/printing.gyp | 22 |
5 files changed, 14 insertions, 39 deletions
diff --git a/build/common.gypi b/build/common.gypi index b8a31eba..4d5836e 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -392,7 +392,7 @@ 'NACL_WIN64', ], }], - ['OS=="mac" or (OS=="linux" and chromeos==0 and target_arch!="arm")', { + ['OS=="linux" and chromeos==0 and target_arch!="arm"', { 'use_cups%': 1, }, { 'use_cups%': 0, diff --git a/chrome/chrome.gyp b/chrome/chrome.gyp index b1e8ebb..961d908 100644 --- a/chrome/chrome.gyp +++ b/chrome/chrome.gyp @@ -1165,6 +1165,12 @@ ], }], ['use_cups==1', { + 'link_settings': { + 'libraries': [ + '-lcups', + '-lgcrypt', + ], + }, 'defines': [ # CP_PRINT_SYSTEM_AVAILABLE disables default dummy implementation # of cloud print system, and allows to use custom implementaiton. @@ -1173,22 +1179,6 @@ 'sources': [ 'service/cloud_print/print_system_cups.cc', ], - 'conditions': [ - ['OS=="mac"', { - 'link_settings': { - 'libraries': [ - '$(SDKROOT)/usr/lib/libcups.dylib', - ] - }, - }, { - 'link_settings': { - 'libraries': [ - '-lcups', - '-lgcrypt', - ], - }, - }], - ], }], ['remoting==1', { 'dependencies': [ diff --git a/chrome/service/cloud_print/print_system_cups.cc b/chrome/service/cloud_print/print_system_cups.cc index 12548af..99e3d1d 100644 --- a/chrome/service/cloud_print/print_system_cups.cc +++ b/chrome/service/cloud_print/print_system_cups.cc @@ -7,6 +7,7 @@ #include <cups/cups.h> #include <dlfcn.h> #include <errno.h> +#include <gcrypt.h> #include <pthread.h> #include <list> diff --git a/printing/backend/print_backend_cups.cc b/printing/backend/print_backend_cups.cc index 09fdf1d..9693299 100644 --- a/printing/backend/print_backend_cups.cc +++ b/printing/backend/print_backend_cups.cc @@ -6,9 +6,7 @@ #include <dlfcn.h> #include <errno.h> -#if !defined(OS_MACOSX) #include <gcrypt.h> -#endif #include <pthread.h> #include "base/file_util.h" @@ -20,7 +18,6 @@ #include "googleurl/src/gurl.h" #include "printing/backend/cups_helper.h" -#if !defined(OS_MACOSX) GCRY_THREAD_OPTION_PTHREAD_IMPL; namespace { @@ -67,7 +64,6 @@ class GcryptInitializer { }; } // namespace -#endif namespace printing { @@ -186,10 +182,8 @@ bool PrintBackendCUPS::IsValidPrinter(const std::string& printer_name) { scoped_refptr<PrintBackend> PrintBackend::CreateInstance( const DictionaryValue* print_backend_settings) { -#if !defined(OS_MACOSX) // Initialize gcrypt library. Singleton<GcryptInitializer>::get(); -#endif std::string print_server_url_str; if (print_backend_settings) { diff --git a/printing/printing.gyp b/printing/printing.gyp index 7acb6d7..ac87ab3 100644 --- a/printing/printing.gyp +++ b/printing/printing.gyp @@ -112,6 +112,12 @@ ], }], ['use_cups==1', { + 'link_settings': { + 'libraries': [ + '-lcups', + '-lgcrypt', + ], + }, 'defines': [ # PRINT_BACKEND_AVAILABLE disables the default dummy implementation # of the print backend and enables a custom implementation instead. @@ -122,22 +128,6 @@ 'backend/cups_helper.h', 'backend/print_backend_cups.cc', ], - 'conditions': [ - ['OS=="mac"', { - 'link_settings': { - 'libraries': [ - '$(SDKROOT)/usr/lib/libcups.dylib', - ] - }, - }, { - 'link_settings': { - 'libraries': [ - '-lcups', - '-lgcrypt', - ], - }, - }], - ], }], ], }, |