CheckFunc() is dangerous on Win32 APIs because SCons is not capable
of compensating for __stdcall name mangling on x86 systems using the
Visual Studio compiler.
Change-Id: Iaec49e4d246c02ecfebc5bf70ee0c0620cdde51d
Signed-off-by: David Antler <david.a.antler@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/12839
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Mike Fenelon <mike.fenelon@microsoft.com>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
(cherry picked from commit
823d478bbf5109a4a73c304794179410f984714e)
Reviewed-on: https://gerrit.iotivity.org/gerrit/12955
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
common_env = env.Clone()
-######################################################################
-# Build flags
-######################################################################
-common_conf = Configure(common_env)
-if common_conf.CheckFunc('QueryPerformanceFrequency'):
- common_env.AppendUnique(CPPDEFINES = ['HAVE_QUERYPERFORMANCEFREQUENCY'])
-common_env = common_conf.Finish()
-
######################################################################
# Source files and Targets
######################################################################
#if defined(HAVE_WINDOWS_H)
# include <windows.h>
+# define HAVE_QUERYPERFORMANCEFREQUENCY
#elif !defined(WITH_ARDUINO)
# if _POSIX_TIMERS > 0
# include <time.h> // For clock_gettime()