build: Change HAVE_OSX_SECURITY to a more general HAVE_OSX_FRAMEWORKS

We are starting to use more macOS frameworks and define/build
environment constant name needs to be more general.

Change-Id: I893d436a34c3370a7f12ac681d1796ef5631cc0e
diff --git a/.waf-tools/osx-security.py b/.waf-tools/osx-frameworks.py
similarity index 67%
rename from .waf-tools/osx-security.py
rename to .waf-tools/osx-frameworks.py
index f7f273e..881d3e1 100644
--- a/.waf-tools/osx-security.py
+++ b/.waf-tools/osx-frameworks.py
@@ -4,7 +4,7 @@
 from waflib import Logs, Utils
 from waflib.Configure import conf
 
-OSX_SECURITY_CODE='''
+OSX_SECURITY_CODE = '''
 #include <CoreFoundation/CoreFoundation.h>
 #include <Security/Security.h>
 #include <Security/SecRandom.h>
@@ -14,7 +14,7 @@
 '''
 
 @conf
-def check_osx_security(conf, *k, **kw):
+def check_osx_frameworks(conf, *k, **kw):
     if Utils.unversioned_sys_platform() == "darwin":
         try:
             conf.check_cxx(framework_name='CoreFoundation', uselib_store='OSX_COREFOUNDATION',
@@ -22,11 +22,12 @@
             conf.check_cxx(framework_name='CoreServices', uselib_store='OSX_CORESERVICES',
                            mandatory=True)
             conf.check_cxx(framework_name='Security', uselib_store='OSX_SECURITY',
-                           define_name='HAVE_SECURITY', use="OSX_COREFOUNDATION",
-                           fragment=OSX_SECURITY_CODE, mandatory=True)
+                           use='OSX_COREFOUNDATION', fragment=OSX_SECURITY_CODE,
+                           mandatory=True)
 
-            conf.define('HAVE_OSX_SECURITY', 1)
-            conf.env['HAVE_OSX_SECURITY'] = True
+            conf.define('HAVE_OSX_FRAMEWORKS', 1)
+            conf.env['HAVE_OSX_FRAMEWORKS'] = True
         except:
-            Logs.warn("Compiling on OSX, but CoreFoundation, CoreServices, or Security framework is not functional.")
-            Logs.warn("The frameworks are known to work only with Apple-specific compilers: llvm-gcc-4.2 or clang")
+            Logs.warn("Compiling on OSX, but CoreFoundation, CoreServices, or Security " +
+                      "framework is not functional.")
+            Logs.warn("The frameworks are known to work only with the Apple clang compiler")