summaryrefslogtreecommitdiffstats
path: root/redhat/applications/ktorrent/bp007-355c6b69.diff
blob: dd4d761431480dcc243537e4a990e36d5853280a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
commit 355c6b69c69b0bc8cf10b7a3c846b5d6ca27abc4
Author: Darrell Anderson <[email protected]>
Date:   1332640454 -0500

    Change default configuration to use external geoip database when found and
    use internal database only when external database is not found.
    This resolves bug report 443.

diff --git a/configure.in b/configure.in
index 31a7116..fc4482e 100644
--- a/configure.in
+++ b/configure.in
@@ -191,7 +191,7 @@ AC_ARG_ENABLE(geoip,
      esac],[geoip=true])
 
 AC_ARG_ENABLE(system-geoip,
-    [AS_HELP_STRING(--enable-system-geoip,[Enables use of system-wide GeoIP database (implies --disable-geoip) (no by default)])],
+    [AS_HELP_STRING(--enable-system-geoip,[Enables use of system-wide GeoIP database (implies --disable-geoip) (auto by default)])],
     [case "${enableval}" in
         yes) if test "$have_system_geoip" = yes; then
                 system_geoip=true
@@ -199,9 +199,18 @@ AC_ARG_ENABLE(system-geoip,
              else
                 AC_MSG_ERROR(cannot enable system geoip. GeoIP library headers were not found on your system)
              fi ;;
-        no) system_geoip=true ;;
+        no) system_geoip=false ;;
         *) AC_MSG_ERROR(bad value ${enableval} for --enable-system-geoip) ;;
-    esac],[system_geoip=false])
+    esac],[system_geoip=auto])
+
+if test x$system_geoip = xauto; then
+    if test "$have_system_geoip" = yes; then
+        system_geoip=true
+        geoip=false
+    else
+        system_geoip=false
+    fi
+fi
 
 AM_CONDITIONAL(ENABLE_GEOIP, test x$geoip = xtrue)
 AM_CONDITIONAL(USE_SYSTEM_GEOIP, test x$system_geoip = xtrue)
@@ -212,12 +221,20 @@ fi
 
 
 AC_ARG_ENABLE(builtin-country-flags,
-    [AS_HELP_STRING(--enable-builtin-country-flags,[Install and prefer builtin country flags to the ones provided by KDE (yes by default)])],
+    [AS_HELP_STRING(--enable-builtin-country-flags,[Install and prefer builtin country flags to the ones provided by KDE (auto by default)])],
     [case "${enableval}" in
         yes) builtin_country_flags=true ;;
         no) builtin_country_flags=false ;;
         *) AC_MSG_ERROR(bad value ${enableval} for --enable-builtin-country-flags) ;;
-    esac],[builtin_country_flags=true])
+    esac],[builtin_country_flags=auto])
+
+if test x$builtin_country_flags = xauto; then
+    if test x$geoip = xtrue; then
+        builtin_country_flags=true
+    else
+        builtin_country_flags=false
+    fi
+fi
 
 AM_CONDITIONAL(ENABLE_BUILTIN_COUNTRY_FLAGS, test x$builtin_country_flags = xtrue)
 
diff --git a/configure.in.in b/configure.in.in
index fae7ea7..438fff9 100644
--- a/configure.in.in
+++ b/configure.in.in
@@ -126,7 +126,7 @@ AC_ARG_ENABLE(geoip,
      esac],[geoip=true])
 
 AC_ARG_ENABLE(system-geoip,
-    [AS_HELP_STRING(--enable-system-geoip,[Enables use of system-wide GeoIP database (implies --disable-geoip) (no by default)])],
+    [AS_HELP_STRING(--enable-system-geoip,[Enables use of system-wide GeoIP database (implies --disable-geoip) (auto by default)])],
     [case "${enableval}" in
         yes) if test "$have_system_geoip" = yes; then
                 system_geoip=true
@@ -134,9 +134,18 @@ AC_ARG_ENABLE(system-geoip,
              else
                 AC_MSG_ERROR(cannot enable system geoip. GeoIP library headers were not found on your system)
              fi ;;
-        no) system_geoip=true ;;
+        no) system_geoip=false ;;
         *) AC_MSG_ERROR(bad value ${enableval} for --enable-system-geoip) ;;
-    esac],[system_geoip=false])
+    esac],[system_geoip=auto])
+
+if test x$system_geoip = xauto; then
+    if test "$have_system_geoip" = yes; then
+        system_geoip=true
+        geoip=false
+    else
+        system_geoip=false
+    fi
+fi
 
 AM_CONDITIONAL(ENABLE_GEOIP, test x$geoip = xtrue)
 AM_CONDITIONAL(USE_SYSTEM_GEOIP, test x$system_geoip = xtrue)
@@ -147,12 +156,20 @@ fi
 
 
 AC_ARG_ENABLE(builtin-country-flags,
-    [AS_HELP_STRING(--enable-builtin-country-flags,[Install and prefer builtin country flags to the ones provided by KDE (yes by default)])],
+    [AS_HELP_STRING(--enable-builtin-country-flags,[Install and prefer builtin country flags to the ones provided by KDE (auto by default)])],
     [case "${enableval}" in
         yes) builtin_country_flags=true ;;
         no) builtin_country_flags=false ;;
         *) AC_MSG_ERROR(bad value ${enableval} for --enable-builtin-country-flags) ;;
-    esac],[builtin_country_flags=true])
+    esac],[builtin_country_flags=auto])
+
+if test x$builtin_country_flags = xauto; then
+    if test x$geoip = xtrue; then
+        builtin_country_flags=true
+    else
+        builtin_country_flags=false
+    fi
+fi
 
 AM_CONDITIONAL(ENABLE_BUILTIN_COUNTRY_FLAGS, test x$builtin_country_flags = xtrue)