// -*- MPC -*-
project: ipv6, vc_warnings, build_files, test_files, svc_conf_files, ace_unicode, ace_idl_dependencies {
  staticflags += ACE_AS_STATIC_LIBS
  includes    += $(ACE_ROOT)
  libpaths    += $(ACE_ROOT)/lib


  specific(prop:microsoft) {
    macro_for_lib_modifier=1
  }

  specific(prop:windows) {
    lit_libs += iphlpapi
  }

  // Support the alternative Borland Make project type
  specific(bmake) {
    unicode_flags += -DACE_USES_WCHAR
    debug_macros += ACE_NO_INLINE=1
    platform_libs += iphlpapi
    lit_libs -= iphlpapi
  }

  verbatim(cmake, top, 1) {
    set(ACE_ROOT $ENV{ACE_ROOT})
    if(WIN32)
    "  link_libraries(iphlpapi)"
    endif()
  }

  specific(cdt6) {
    win32::platform_libs += ws2_32 mswsock netapi32
    release::macros += ACE_NDEBUG
  }

  // Link To Android Logging Library for Log_Msg_Android_Logcat
  specific(gnuace) {
    linkflags += $(if $(android_abi),-llog)
  }
}

feature(ace_inline) {
  specific(cdt6,cdt7) {
    macros += __ACE_INLINE__
  }
}

feature(!ace_inline) {
  specific(cdt6,cdt7) {
    macros += ACE_NO_INLINE
  }
}

feature(!threads) {
  specific(cdt6,cdt7) {
    macros += ACE_MT_SAFE=0
    // and without threads we must remove support for AIO.
    macros -= ACE_HAS_AIO_CALLS
    platform_libs -= rt
  }
}

feature(ace_languagestandard2017) {
  specific(vs2017,vs2019,vs2022) {
    LanguageStandard = stdcpp17
  }
  specific(cmake) {
    languagestandard = 17
  }
}
