mirror of
https://github.com/motioneye-project/motioneyeos.git
synced 2025-08-02 07:57:43 +00:00
- pull kbuild from 2.6.22.7. This should fix the ncurses detection for dylib et al
This commit is contained in:
parent
e640e6a8ef
commit
0d888e3677
@ -143,6 +143,7 @@ endif
|
|||||||
|
|
||||||
clean-files := lkc_defs.h qconf.moc .tmp_qtcheck \
|
clean-files := lkc_defs.h qconf.moc .tmp_qtcheck \
|
||||||
.tmp_gtkcheck zconf.tab.c lex.zconf.c zconf.hash.c
|
.tmp_gtkcheck zconf.tab.c lex.zconf.c zconf.hash.c
|
||||||
|
clean-files += mconf qconf gconf
|
||||||
|
|
||||||
# Needed for systems without gettext
|
# Needed for systems without gettext
|
||||||
KBUILD_HAVE_NLS := $(shell \
|
KBUILD_HAVE_NLS := $(shell \
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
This is a copy of the kconfig code in the kernel (currently 2.6.21.5) tweaked to
|
This is a copy of the kconfig code in the kernel (currently 2.6.22.7) tweaked to
|
||||||
suit Buildroot.
|
suit Buildroot.
|
||||||
|
|
||||||
To update:
|
To update:
|
||||||
@ -6,7 +6,7 @@ To update:
|
|||||||
cd package/config.new
|
cd package/config.new
|
||||||
cp /usr/src/linux/Documentation/kbuild/kconfig-language.txt .
|
cp /usr/src/linux/Documentation/kbuild/kconfig-language.txt .
|
||||||
mv Makefile Makefile.kconfig
|
mv Makefile Makefile.kconfig
|
||||||
patch -p1 < ../config/kconfig-to-buildroot.patch
|
patch -p1 < ../config/kconfig-to-buildroot2.patch
|
||||||
cp ../config/README.buildroot2 .
|
cp ../config/README.buildroot2 .
|
||||||
cp ../config/foo.h .
|
cp ../config/foo.h .
|
||||||
cp ../config/Makefile .
|
cp ../config/Makefile .
|
||||||
|
@ -558,6 +558,7 @@ int main(int ac, char **av)
|
|||||||
if (stat(".config", &tmpstat)) {
|
if (stat(".config", &tmpstat)) {
|
||||||
printf(_("***\n"
|
printf(_("***\n"
|
||||||
"*** You have not yet configured Buildroot!\n"
|
"*** You have not yet configured Buildroot!\n"
|
||||||
|
"*** (missing .config file)\n"
|
||||||
"***\n"
|
"***\n"
|
||||||
"*** Please run some configurator (e.g. \"make oldconfig\" or\n"
|
"*** Please run some configurator (e.g. \"make oldconfig\" or\n"
|
||||||
"*** \"make menuconfig\" or \"make config\").\n"
|
"*** \"make menuconfig\" or \"make config\").\n"
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -2264,7 +2264,7 @@ FILE *zconf_fopen(const char *name)
|
|||||||
FILE *f;
|
FILE *f;
|
||||||
|
|
||||||
f = fopen(name, "r");
|
f = fopen(name, "r");
|
||||||
if (!f && name[0] != '/') {
|
if (!f && name != NULL && name[0] != '/') {
|
||||||
env = getenv(SRCTREE);
|
env = getenv(SRCTREE);
|
||||||
if (env) {
|
if (env) {
|
||||||
sprintf(fullname, "%s/%s", env, name);
|
sprintf(fullname, "%s/%s", env, name);
|
||||||
|
@ -64,6 +64,7 @@ int zconf_lineno(void);
|
|||||||
char *zconf_curname(void);
|
char *zconf_curname(void);
|
||||||
|
|
||||||
/* confdata.c */
|
/* confdata.c */
|
||||||
|
const char *conf_get_configname(void);
|
||||||
char *conf_get_default_confname(void);
|
char *conf_get_default_confname(void);
|
||||||
void sym_set_change_count(int count);
|
void sym_set_change_count(int count);
|
||||||
void sym_add_change_count(int count);
|
void sym_add_change_count(int count);
|
||||||
|
@ -4,21 +4,15 @@
|
|||||||
# What library to link
|
# What library to link
|
||||||
ldflags()
|
ldflags()
|
||||||
{
|
{
|
||||||
$cc -print-file-name=libncursesw.so | grep -q /
|
for ext in so a dylib ; do
|
||||||
if [ $? -eq 0 ]; then
|
for lib in ncursesw ncurses curses ; do
|
||||||
echo '-lncursesw'
|
$cc -print-file-name=lib${lib}.${ext} | grep -q /
|
||||||
exit
|
if [ $? -eq 0 ]; then
|
||||||
fi
|
echo "-l${lib}"
|
||||||
$cc -print-file-name=libncurses.so | grep -q /
|
exit
|
||||||
if [ $? -eq 0 ]; then
|
fi
|
||||||
echo '-lncurses'
|
done
|
||||||
exit
|
done
|
||||||
fi
|
|
||||||
$cc -print-file-name=libcurses.so | grep -q /
|
|
||||||
if [ $? -eq 0 ]; then
|
|
||||||
echo '-lcurses'
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -188,6 +188,7 @@ int on_key_esc(WINDOW *win);
|
|||||||
int on_key_resize(void);
|
int on_key_resize(void);
|
||||||
|
|
||||||
void init_dialog(const char *backtitle);
|
void init_dialog(const char *backtitle);
|
||||||
|
void set_dialog_backtitle(const char *backtitle);
|
||||||
void reset_dialog(void);
|
void reset_dialog(void);
|
||||||
void end_dialog(void);
|
void end_dialog(void);
|
||||||
void attr_clear(WINDOW * win, int height, int width, chtype attr);
|
void attr_clear(WINDOW * win, int height, int width, chtype attr);
|
||||||
|
@ -272,6 +272,11 @@ void init_dialog(const char *backtitle)
|
|||||||
color_setup(getenv("MENUCONFIG_COLOR"));
|
color_setup(getenv("MENUCONFIG_COLOR"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void set_dialog_backtitle(const char *backtitle)
|
||||||
|
{
|
||||||
|
dlg.backtitle = backtitle;
|
||||||
|
}
|
||||||
|
|
||||||
void reset_dialog(void)
|
void reset_dialog(void)
|
||||||
{
|
{
|
||||||
initscr(); /* Init curses */
|
initscr(); /* Init curses */
|
||||||
@ -336,7 +341,7 @@ void print_autowrap(WINDOW * win, const char *prompt, int width, int y, int x)
|
|||||||
newl = 1;
|
newl = 1;
|
||||||
word = tempstr;
|
word = tempstr;
|
||||||
while (word && *word) {
|
while (word && *word) {
|
||||||
sp = index(word, ' ');
|
sp = strchr(word, ' ');
|
||||||
if (sp)
|
if (sp)
|
||||||
*sp++ = 0;
|
*sp++ = 0;
|
||||||
|
|
||||||
@ -348,7 +353,7 @@ void print_autowrap(WINDOW * win, const char *prompt, int width, int y, int x)
|
|||||||
if (wlen > room ||
|
if (wlen > room ||
|
||||||
(newl && wlen < 4 && sp
|
(newl && wlen < 4 && sp
|
||||||
&& wlen + 1 + strlen(sp) > room
|
&& wlen + 1 + strlen(sp) > room
|
||||||
&& (!(sp2 = index(sp, ' '))
|
&& (!(sp2 = strchr(sp, ' '))
|
||||||
|| wlen + 1 + (sp2 - sp) > room))) {
|
|| wlen + 1 + (sp2 - sp) > room))) {
|
||||||
cur_y++;
|
cur_y++;
|
||||||
cur_x = x;
|
cur_x = x;
|
||||||
|
@ -26,7 +26,6 @@
|
|||||||
#include "lkc.h"
|
#include "lkc.h"
|
||||||
#include "lxdialog/dialog.h"
|
#include "lxdialog/dialog.h"
|
||||||
|
|
||||||
static char menu_backtitle[128];
|
|
||||||
static const char mconf_readme[] = N_(
|
static const char mconf_readme[] = N_(
|
||||||
"Overview\n"
|
"Overview\n"
|
||||||
"--------\n"
|
"--------\n"
|
||||||
@ -269,7 +268,6 @@ search_help[] = N_(
|
|||||||
" USB$ => find all CONFIG_ symbols ending with USB\n"
|
" USB$ => find all CONFIG_ symbols ending with USB\n"
|
||||||
"\n");
|
"\n");
|
||||||
|
|
||||||
static char filename[PATH_MAX+1] = ".config";
|
|
||||||
static int indent;
|
static int indent;
|
||||||
static struct termios ios_org;
|
static struct termios ios_org;
|
||||||
static int rows = 0, cols = 0;
|
static int rows = 0, cols = 0;
|
||||||
@ -393,6 +391,28 @@ static struct gstr get_relations_str(struct symbol **sym_arr)
|
|||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static char filename[PATH_MAX+1];
|
||||||
|
static void set_config_filename(const char *config_filename)
|
||||||
|
{
|
||||||
|
static char menu_backtitle[PATH_MAX+128];
|
||||||
|
int size;
|
||||||
|
struct symbol *sym;
|
||||||
|
|
||||||
|
sym = sym_lookup("VERSION", 0);
|
||||||
|
sym_calc_value(sym);
|
||||||
|
size = snprintf(menu_backtitle, sizeof(menu_backtitle),
|
||||||
|
_("%s - buildroot v%s Configuration"),
|
||||||
|
config_filename, sym_get_string_value(sym));
|
||||||
|
if (size >= sizeof(menu_backtitle))
|
||||||
|
menu_backtitle[sizeof(menu_backtitle)-1] = '\0';
|
||||||
|
set_dialog_backtitle(menu_backtitle);
|
||||||
|
|
||||||
|
size = snprintf(filename, sizeof(filename), "%s", config_filename);
|
||||||
|
if (size >= sizeof(filename))
|
||||||
|
filename[sizeof(filename)-1] = '\0';
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static void search_conf(void)
|
static void search_conf(void)
|
||||||
{
|
{
|
||||||
struct symbol **sym_arr;
|
struct symbol **sym_arr;
|
||||||
@ -814,8 +834,10 @@ static void conf_load(void)
|
|||||||
case 0:
|
case 0:
|
||||||
if (!dialog_input_result[0])
|
if (!dialog_input_result[0])
|
||||||
return;
|
return;
|
||||||
if (!conf_read(dialog_input_result))
|
if (!conf_read(dialog_input_result)) {
|
||||||
|
set_config_filename(dialog_input_result);
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
show_textbox(NULL, _("File does not exist!"), 5, 38);
|
show_textbox(NULL, _("File does not exist!"), 5, 38);
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
@ -838,8 +860,10 @@ static void conf_save(void)
|
|||||||
case 0:
|
case 0:
|
||||||
if (!dialog_input_result[0])
|
if (!dialog_input_result[0])
|
||||||
return;
|
return;
|
||||||
if (!conf_write(dialog_input_result))
|
if (!conf_write(dialog_input_result)) {
|
||||||
|
set_config_filename(dialog_input_result);
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
show_textbox(NULL, _("Can't create file! Probably a nonexistent directory."), 5, 60);
|
show_textbox(NULL, _("Can't create file! Probably a nonexistent directory."), 5, 60);
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
@ -858,7 +882,6 @@ static void conf_cleanup(void)
|
|||||||
|
|
||||||
int main(int ac, char **av)
|
int main(int ac, char **av)
|
||||||
{
|
{
|
||||||
struct symbol *sym;
|
|
||||||
char *mode;
|
char *mode;
|
||||||
int res;
|
int res;
|
||||||
|
|
||||||
@ -869,11 +892,6 @@ int main(int ac, char **av)
|
|||||||
conf_parse(av[1]);
|
conf_parse(av[1]);
|
||||||
conf_read(NULL);
|
conf_read(NULL);
|
||||||
|
|
||||||
sym = sym_lookup("VERSION", 0);
|
|
||||||
sym_calc_value(sym);
|
|
||||||
sprintf(menu_backtitle, _("Buildroot v%s Configuration"),
|
|
||||||
sym_get_string_value(sym));
|
|
||||||
|
|
||||||
mode = getenv("MENUCONFIG_MODE");
|
mode = getenv("MENUCONFIG_MODE");
|
||||||
if (mode) {
|
if (mode) {
|
||||||
if (!strcasecmp(mode, "single_menu"))
|
if (!strcasecmp(mode, "single_menu"))
|
||||||
@ -884,7 +902,8 @@ int main(int ac, char **av)
|
|||||||
atexit(conf_cleanup);
|
atexit(conf_cleanup);
|
||||||
init_wsize();
|
init_wsize();
|
||||||
reset_dialog();
|
reset_dialog();
|
||||||
init_dialog(menu_backtitle);
|
init_dialog(NULL);
|
||||||
|
set_config_filename(conf_get_configname());
|
||||||
do {
|
do {
|
||||||
conf(&rootmenu);
|
conf(&rootmenu);
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
@ -901,7 +920,7 @@ int main(int ac, char **av)
|
|||||||
|
|
||||||
switch (res) {
|
switch (res) {
|
||||||
case 0:
|
case 0:
|
||||||
if (conf_write(NULL)) {
|
if (conf_write(filename)) {
|
||||||
fprintf(stderr, _("\n\n"
|
fprintf(stderr, _("\n\n"
|
||||||
"Error during writing of the Buildroot configuration.\n"
|
"Error during writing of the Buildroot configuration.\n"
|
||||||
"Your Buildroot configuration changes were NOT saved."
|
"Your Buildroot configuration changes were NOT saved."
|
||||||
|
@ -203,7 +203,7 @@ void sym_check_prop(struct symbol *sym)
|
|||||||
else if (sym2->type == S_UNKNOWN)
|
else if (sym2->type == S_UNKNOWN)
|
||||||
prop_warn(prop,
|
prop_warn(prop,
|
||||||
"'select' used by config symbol '%s' "
|
"'select' used by config symbol '%s' "
|
||||||
"refer to undefined symbol '%s'",
|
"refers to undefined symbol '%s'",
|
||||||
sym->name, sym2->name);
|
sym->name, sym2->name);
|
||||||
else if (sym2->type != S_BOOLEAN && sym2->type != S_TRISTATE)
|
else if (sym2->type != S_BOOLEAN && sym2->type != S_TRISTATE)
|
||||||
prop_warn(prop,
|
prop_warn(prop,
|
||||||
|
@ -1182,7 +1182,7 @@ void ConfigInfoView::contentsContextMenuEvent(QContextMenuEvent *e)
|
|||||||
Parent::contentsContextMenuEvent(e);
|
Parent::contentsContextMenuEvent(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
ConfigSearchWindow::ConfigSearchWindow(QWidget* parent, const char *name)
|
ConfigSearchWindow::ConfigSearchWindow(ConfigMainWindow* parent, const char *name)
|
||||||
: Parent(parent, name), result(NULL)
|
: Parent(parent, name), result(NULL)
|
||||||
{
|
{
|
||||||
setCaption("Search Config");
|
setCaption("Search Config");
|
||||||
@ -1206,6 +1206,9 @@ ConfigSearchWindow::ConfigSearchWindow(QWidget* parent, const char *name)
|
|||||||
info = new ConfigInfoView(split, name);
|
info = new ConfigInfoView(split, name);
|
||||||
connect(list->list, SIGNAL(menuChanged(struct menu *)),
|
connect(list->list, SIGNAL(menuChanged(struct menu *)),
|
||||||
info, SLOT(setInfo(struct menu *)));
|
info, SLOT(setInfo(struct menu *)));
|
||||||
|
connect(list->list, SIGNAL(menuChanged(struct menu *)),
|
||||||
|
parent, SLOT(setMenuLink(struct menu *)));
|
||||||
|
|
||||||
layout1->addWidget(split);
|
layout1->addWidget(split);
|
||||||
|
|
||||||
if (name) {
|
if (name) {
|
||||||
|
@ -279,7 +279,7 @@ class ConfigSearchWindow : public QDialog {
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
typedef class QDialog Parent;
|
typedef class QDialog Parent;
|
||||||
public:
|
public:
|
||||||
ConfigSearchWindow(QWidget* parent, const char *name = 0);
|
ConfigSearchWindow(ConfigMainWindow* parent, const char *name = 0);
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void saveSettings(void);
|
void saveSettings(void);
|
||||||
|
@ -786,13 +786,15 @@ static struct symbol *sym_check_expr_deps(struct expr *e)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* return NULL when dependencies are OK */
|
||||||
struct symbol *sym_check_deps(struct symbol *sym)
|
struct symbol *sym_check_deps(struct symbol *sym)
|
||||||
{
|
{
|
||||||
struct symbol *sym2;
|
struct symbol *sym2;
|
||||||
struct property *prop;
|
struct property *prop;
|
||||||
|
|
||||||
if (sym->flags & SYMBOL_CHECK) {
|
if (sym->flags & SYMBOL_CHECK) {
|
||||||
printf("Warning! Found recursive dependency: %s", sym->name);
|
fprintf(stderr, "%s:%d:error: found recursive dependency: %s",
|
||||||
|
sym->prop->file->name, sym->prop->lineno, sym->name);
|
||||||
return sym;
|
return sym;
|
||||||
}
|
}
|
||||||
if (sym->flags & SYMBOL_CHECKED)
|
if (sym->flags & SYMBOL_CHECKED)
|
||||||
@ -816,13 +818,8 @@ struct symbol *sym_check_deps(struct symbol *sym)
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
out:
|
out:
|
||||||
if (sym2) {
|
if (sym2)
|
||||||
printf(" %s", sym->name);
|
fprintf(stderr, " -> %s%s", sym->name, sym2 == sym? "\n": "");
|
||||||
if (sym2 == sym) {
|
|
||||||
printf("\n");
|
|
||||||
sym2 = NULL;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
sym->flags &= ~SYMBOL_CHECK;
|
sym->flags &= ~SYMBOL_CHECK;
|
||||||
return sym2;
|
return sym2;
|
||||||
}
|
}
|
||||||
|
@ -44,7 +44,7 @@ int file_write_dep(const char *name)
|
|||||||
else
|
else
|
||||||
fprintf(out, "\t%s\n", file->name);
|
fprintf(out, "\t%s\n", file->name);
|
||||||
}
|
}
|
||||||
fprintf(out, "\ninclude/config/auto.conf: \\\n"
|
fprintf(out, "\n$(BR2_DEPENDS_DIR)/config/auto.conf: \\\n"
|
||||||
"\t$(deps_config)\n\n"
|
"\t$(deps_config)\n\n"
|
||||||
"$(deps_config): ;\n");
|
"$(deps_config): ;\n");
|
||||||
fclose(out);
|
fclose(out);
|
||||||
|
@ -265,7 +265,7 @@ FILE *zconf_fopen(const char *name)
|
|||||||
FILE *f;
|
FILE *f;
|
||||||
|
|
||||||
f = fopen(name, "r");
|
f = fopen(name, "r");
|
||||||
if (!f && name[0] != '/') {
|
if (!f && name != NULL && name[0] != '/') {
|
||||||
env = getenv(SRCTREE);
|
env = getenv(SRCTREE);
|
||||||
if (env) {
|
if (env) {
|
||||||
sprintf(fullname, "%s/%s", env, name);
|
sprintf(fullname, "%s/%s", env, name);
|
||||||
|
@ -2132,9 +2132,11 @@ void conf_parse(const char *name)
|
|||||||
}
|
}
|
||||||
menu_finalize(&rootmenu);
|
menu_finalize(&rootmenu);
|
||||||
for_all_symbols(i, sym) {
|
for_all_symbols(i, sym) {
|
||||||
sym_check_deps(sym);
|
if (sym_check_deps(sym))
|
||||||
|
zconfnerrs++;
|
||||||
}
|
}
|
||||||
|
if (zconfnerrs)
|
||||||
|
exit(1);
|
||||||
sym_set_change_count(1);
|
sym_set_change_count(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -501,9 +501,11 @@ void conf_parse(const char *name)
|
|||||||
}
|
}
|
||||||
menu_finalize(&rootmenu);
|
menu_finalize(&rootmenu);
|
||||||
for_all_symbols(i, sym) {
|
for_all_symbols(i, sym) {
|
||||||
sym_check_deps(sym);
|
if (sym_check_deps(sym))
|
||||||
|
zconfnerrs++;
|
||||||
}
|
}
|
||||||
|
if (zconfnerrs)
|
||||||
|
exit(1);
|
||||||
sym_set_change_count(1);
|
sym_set_change_count(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user