Kaydet (Commit) 4ff9a995 authored tarafından Eike Rathke's avatar Eike Rathke

langtag: use ENABLE_LIBLANGTAG in unit test

üst d724f647
...@@ -23,23 +23,17 @@ $(eval $(call gb_CppunitTest_use_libraries,i18npool_test_languagetag,\ ...@@ -23,23 +23,17 @@ $(eval $(call gb_CppunitTest_use_libraries,i18npool_test_languagetag,\
$(gb_STDLIBS) \ $(gb_STDLIBS) \
)) ))
ifneq ($(OS),ANDROID) ifeq ($(ENABLE_LIBLANGTAG),YES)
ifneq ($(OS),IOS)
$(eval $(call gb_CppunitTest_use_externals,i18npool_test_languagetag,\ $(eval $(call gb_CppunitTest_use_externals,i18npool_test_languagetag,\
liblangtag \ liblangtag \
glib \ glib \
))
endif
endif
$(eval $(call gb_CppunitTest_use_externals,i18npool_test_languagetag,\
libxml2 \ libxml2 \
)) ))
$(eval $(call gb_CppunitTest_add_defs,i18npool_test_languagetag,-DENABLE_LIBLANGTAG))
ifeq ($(SYSTEM_LIBLANGTAG),YES) ifeq ($(SYSTEM_LIBLANGTAG),YES)
$(eval $(call gb_CppunitTest_add_cxxflags,i18npool_test_languagetag,\ $(eval $(call gb_CppunitTest_add_defs,i18npool_test_languagetag,-DSYSTEM_LIBLANGTAG))
-DSYSTEM_LIBLANGTAG \ endif
))
endif endif
$(eval $(call gb_CppunitTest_set_include,i18npool_test_languagetag,\ $(eval $(call gb_CppunitTest_set_include,i18npool_test_languagetag,\
......
...@@ -26,7 +26,11 @@ using namespace com::sun::star; ...@@ -26,7 +26,11 @@ using namespace com::sun::star;
// To test the replacement code add '&& 0' and also in // To test the replacement code add '&& 0' and also in
// source/languagetag/languagetag.cxx // source/languagetag/languagetag.cxx
#define USE_LIBLANGTAG (!defined(ANDROID) && !defined(IOS)) #if defined(ENABLE_LIBLANGTAG)
#define USE_LIBLANGTAG 1
#else
#define USE_LIBLANGTAG 0
#endif
namespace { namespace {
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
//#define erDEBUG //#define erDEBUG
#ifdef ENABLE_LIBLANGTAG #if defined(ENABLE_LIBLANGTAG)
#include <liblangtag/langtag.h> #include <liblangtag/langtag.h>
#else #else
/* Replacement code for LGPL phobic and Android systems. /* Replacement code for LGPL phobic and Android systems.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment