| 688 ####################################################################### |
688 ####################################################################### |
| 689 # Check for KWallet headers |
689 # Check for KWallet headers |
| 690 ####################################################################### |
690 ####################################################################### |
| 691 |
691 |
| 692 enable_kwallet = get_option('kwallet') and not IS_WIN32 |
692 enable_kwallet = get_option('kwallet') and not IS_WIN32 |
| 693 enable_kwallet = false |
|
| 694 |
693 |
| 695 if enable_kwallet |
694 if enable_kwallet |
| 696 # Ensure C++ compiler works |
695 # Ensure C++ compiler works |
| 697 add_languages('cpp') |
696 add_languages('cpp') |
| 698 cxx_compiler = meson.get_compiler('cpp') |
697 cxx_compiler = meson.get_compiler('cpp') |
| 699 |
698 add_project_arguments('-DHAVE_CONFIG_H=1', language : 'cpp') |
| 700 qt4 = dependency('qt4', modules : 'Core', required : force_deps) |
699 |
| 701 enable_kwallet = qt4.found() |
700 qt5 = import('qt5') |
| 702 endif |
701 |
| 703 |
702 qt5_dep = dependency('qt5', modules: ['Core']) |
| 704 if enable_kwallet |
703 |
| 705 # AC_MSG_CHECKING([for metaobject compiler]) |
704 kwallet = dependency('KF5Wallet') |
| 706 # MOC=`$PKG_CONFIG --variable=moc_location QtCore` |
|
| 707 # AC_SUBST(MOC) |
|
| 708 # AC_MSG_RESULT([$MOC]) |
|
| 709 # |
|
| 710 # KWALLET_CXXFLAGS='' |
|
| 711 # KWALLET_LIBS='' |
|
| 712 # if test -z '$with_kwallet_includes' || test -z '$with_kwallet_libs'; then |
|
| 713 # AC_CHECK_PROG(KDE4_CONFIG, kde4-config, kde4-config, no) |
|
| 714 # if test 'x$KDE4_CONFIG' = 'xno'; then |
|
| 715 # enable_kwallet = false |
|
| 716 # if test 'x$force_deps' = 'xyes'; then |
|
| 717 # AC_MSG_ERROR([ |
|
| 718 #kde4-config not found. $KDE4_CONFIG |
|
| 719 #Use -Dkwallet=false if you do not need KWallet support. |
|
| 720 #]) |
|
| 721 # fi |
|
| 722 # fi |
|
| 723 # fi |
|
| 724 endif |
|
| 725 |
|
| 726 if enable_kwallet |
|
| 727 # if test 'x$KDE4_CONFIG' != 'xno'; then |
|
| 728 # KWALLET_CXXFLAGS='$QT4_CFLAGS -I`$KDE4_CONFIG --path include`' |
|
| 729 # fi |
|
| 730 # CPPFLAGS='$CPPFLAGS $KWALLET_CXXFLAGS' |
|
| 731 # AC_CHECK_HEADER([kwallet.h], , [ |
|
| 732 # enable_kwallet = false |
|
| 733 # if test 'x$force_deps' = 'xyes'; then |
|
| 734 # AC_MSG_ERROR([ |
|
| 735 #KWallet development headers not found. |
|
| 736 #Use -Dkwallet=false if you do not need KWallet support. |
|
| 737 #]) |
|
| 738 # fi |
|
| 739 #]) |
|
| 740 endif |
|
| 741 |
|
| 742 if enable_kwallet |
|
| 743 # AC_MSG_CHECKING([for KWallet libraries]) |
|
| 744 # if test 'x$KDE4_CONFIG' != 'xno'; then |
|
| 745 # KWALLET_LIBS='-L`$KDE4_CONFIG --install lib`/kde4/devel -lkdeui' |
|
| 746 # else |
|
| 747 # KWALLET_LIBS='-lkdeui' |
|
| 748 # fi |
|
| 749 # KWALLET_LIBS='$KWALLET_LIBS' |
|
| 750 # LIBS='$LIBS $KWALLET_LIBS $QT4_LIBS' |
|
| 751 # AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <kwallet.h>], |
|
| 752 # [KWallet::Wallet::LocalWallet();])], [AC_MSG_RESULT([yes])], |
|
| 753 # [ |
|
| 754 # AC_MSG_RESULT(no) |
|
| 755 # enable_kwallet = false |
|
| 756 # if test 'x$force_deps' = 'xyes'; then |
|
| 757 # AC_MSG_ERROR([ |
|
| 758 #KWallet development libraries not found. |
|
| 759 #Use -Dkwallet=false if you do not need KWallet support. |
|
| 760 #]) |
|
| 761 # fi |
|
| 762 # ]) |
|
| 763 endif |
705 endif |
| 764 |
706 |
| 765 ####################################################################### |
707 ####################################################################### |
| 766 # Check for GPlugin 0.28.0 |
708 # Check for GPlugin 0.28.0 |
| 767 ####################################################################### |
709 ####################################################################### |