* (no subject)
@ 2014-10-08 5:41 Kevin Du Huanpeng
0 siblings, 0 replies; only message in thread
From: Kevin Du Huanpeng @ 2014-10-08 5:41 UTC (permalink / raw)
To: barebox
Hi,
I find that most xxx_defconfig stop linking when console support set
to CONSOLE_NONE
compile log like:
http://paste.ubuntu.com/8518456/
- - - -
| Symbol: CONSOLE_NONE [=y] |
| Type : boolean |
| Prompt: none |
| Location: |
| -> General Settings |
| -> console support (<choice> [=y]) |
| Defined at common/Kconfig:522 |
| Depends on: <choice> |
- - - -
most error causes by pr_print undefined.
this macro/function is
defined in:
common/console_common.c
declare in:
include/printk.h
when CONSOLE_NONE is defined,
pr_print is not compiled (rid by #ifndef/#endif) with common/console_common.o
but <printk.h> is included allmost anywhere by including <common.h>
- - - -
#ifndef __COMMON_H_
#define __COMMON_H_ 1
#include <stdio.h>
...
#include <asm/common.h>
#include <printk.h>
- - - -
so using pr_print always can past compile because it is declared by
including <common.h>.
but breaks link.
I am confusing with CONSOLE_NONE, what is it mean?
1. the board don't have a console?
is the board still can have a serial port, but not accepts input?
2. where should the debug messages go?
the serial port is not a console but
when CONSOLE_NONE defined, printf just a nothing but return a 0,
but the pr_print() declared but not defined.
- - - -
FILE: include/stdio.h
static inline int printf(const char *fmt, ...)
{
return 0;
}
- - - -
- - - -
duhuanpeng
(+86)13719074147
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2014-10-08 5:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-08 5:41 Kevin Du Huanpeng
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox