summaryrefslogtreecommitdiff
blob: d90ef94fcc55360d7147166ac168d7ee864724d9 (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
--- lib/defaults.c.orig
+++ lib/defaults.c
@@ -19,7 +19,9 @@
 
 #include "list.h"
 #include "defaults.h"
+#ifdef HAVE_LDAP
 #include "lookup_ldap.h"
+#endif
 #include "log.h"
 #include "automount.h"
 
@@ -197,6 +199,7 @@ static int parse_line(char *line, char *
 	return 1;
 }
 
+#ifdef HAVE_LDAP
 void defaults_free_uris(struct list_head *list)
 {
 	struct list_head *next;
@@ -252,9 +255,11 @@ static unsigned int add_uris(char *value
 
 	return 1;
 }
+#endif
 
 struct list_head *defaults_get_uris(void)
 {
+#ifdef HAVE_LDAP
 	FILE *f;
 	char buf[MAX_LINE_LEN];
 	char *res;
@@ -288,6 +292,9 @@ struct list_head *defaults_get_uris(void
 
 	fclose(f);
 	return list;
+#else
+	return NULL;
+#endif
 }
 
 /*
@@ -450,6 +457,7 @@ unsigned int defaults_get_ldap_network_t
 	return res;
 }
 
+#ifdef HAVE_LDAP
 struct ldap_schema *defaults_get_default_schema(void)
 {
 	struct ldap_schema *schema;
@@ -645,6 +653,7 @@ struct ldap_schema *defaults_get_schema(
 
 	return schema;
 }
+#endif
 
 unsigned int defaults_get_mount_nfs_default_proto(void)
 {