|
@@ -20,7 +20,15 @@ Index: b/confdata.c
|
|
===================================================================
|
|
===================================================================
|
|
--- a/confdata.c
|
|
--- a/confdata.c
|
|
+++ b/confdata.c
|
|
+++ b/confdata.c
|
|
-@@ -70,9 +70,7 @@
|
|
|
|
|
|
+@@ -13,6 +13,7 @@
|
|
|
|
+ #include <string.h>
|
|
|
|
+ #include <time.h>
|
|
|
|
+ #include <unistd.h>
|
|
|
|
++#include <libgen.h>
|
|
|
|
+
|
|
|
|
+ #include "lkc.h"
|
|
|
|
+
|
|
|
|
+@@ -70,9 +71,7 @@
|
|
|
|
|
|
const char *conf_get_autoconfig_name(void)
|
|
const char *conf_get_autoconfig_name(void)
|
|
{
|
|
{
|
|
@@ -31,7 +39,7 @@ Index: b/confdata.c
|
|
}
|
|
}
|
|
|
|
|
|
static char *conf_expand_value(const char *in)
|
|
static char *conf_expand_value(const char *in)
|
|
-@@ -737,6 +735,9 @@
|
|
|
|
|
|
+@@ -737,6 +736,9 @@
|
|
char dirname[PATH_MAX+1], tmpname[PATH_MAX+1], newname[PATH_MAX+1];
|
|
char dirname[PATH_MAX+1], tmpname[PATH_MAX+1], newname[PATH_MAX+1];
|
|
char *env;
|
|
char *env;
|
|
|
|
|
|
@@ -41,7 +49,7 @@ Index: b/confdata.c
|
|
dirname[0] = 0;
|
|
dirname[0] = 0;
|
|
if (name && name[0]) {
|
|
if (name && name[0]) {
|
|
struct stat st;
|
|
struct stat st;
|
|
-@@ -831,6 +832,7 @@
|
|
|
|
|
|
+@@ -831,6 +833,7 @@
|
|
{
|
|
{
|
|
const char *name;
|
|
const char *name;
|
|
char path[PATH_MAX+1];
|
|
char path[PATH_MAX+1];
|
|
@@ -49,7 +57,7 @@ Index: b/confdata.c
|
|
char *s, *d, c;
|
|
char *s, *d, c;
|
|
struct symbol *sym;
|
|
struct symbol *sym;
|
|
struct stat sb;
|
|
struct stat sb;
|
|
-@@ -839,8 +841,20 @@
|
|
|
|
|
|
+@@ -839,8 +842,20 @@
|
|
name = conf_get_autoconfig_name();
|
|
name = conf_get_autoconfig_name();
|
|
conf_read_simple(name, S_DEF_AUTO);
|
|
conf_read_simple(name, S_DEF_AUTO);
|
|
|
|
|
|
@@ -72,7 +80,7 @@ Index: b/confdata.c
|
|
|
|
|
|
res = 0;
|
|
res = 0;
|
|
for_all_symbols(i, sym) {
|
|
for_all_symbols(i, sym) {
|
|
-@@ -933,9 +947,11 @@
|
|
|
|
|
|
+@@ -933,9 +948,11 @@
|
|
close(fd);
|
|
close(fd);
|
|
}
|
|
}
|
|
out:
|
|
out:
|
|
@@ -87,7 +95,7 @@ Index: b/confdata.c
|
|
return res;
|
|
return res;
|
|
}
|
|
}
|
|
|
|
|
|
-@@ -945,25 +961,38 @@
|
|
|
|
|
|
+@@ -945,25 +962,38 @@
|
|
const char *name;
|
|
const char *name;
|
|
FILE *out, *tristate, *out_h;
|
|
FILE *out, *tristate, *out_h;
|
|
int i;
|
|
int i;
|
|
@@ -130,7 +138,7 @@ Index: b/confdata.c
|
|
if (!out_h) {
|
|
if (!out_h) {
|
|
fclose(out);
|
|
fclose(out);
|
|
fclose(tristate);
|
|
fclose(tristate);
|
|
-@@ -995,19 +1024,22 @@
|
|
|
|
|
|
+@@ -995,19 +1025,22 @@
|
|
name = getenv("KCONFIG_AUTOHEADER");
|
|
name = getenv("KCONFIG_AUTOHEADER");
|
|
if (!name)
|
|
if (!name)
|
|
name = "include/generated/autoconf.h";
|
|
name = "include/generated/autoconf.h";
|