[Cbe-oss-dev] [patch 2/4] MARS: Build file cleanup

Geoff Levand geoffrey.levand at am.sony.com
Sun Aug 31 13:32:08 EST 2008


On 08/24/2008 07:28 PM, Kazunori Asayama wrote:
> Geoff Levand wrote:
>> Cleanup build files:
>>  o Use the git revision for package version.
>>  o Add configure options --with-mars-host and --with-mars-mpu to support
>>    platform specific builds.
> 
> It seems to be complicated, and additionally, I don't think all
> combinations of hosts and MPUs will be allowed. Isn't
> '--with-mars-platform' sufficient?

I think it could be.  This multi-platform support still needs work, I
haven't tried to re-factor it down.  The current platform candidates
are:

cell
spursengine
triblade


>>  o Add host lib configure option --with-mars-kernel to allow building with
>>    custom kernels.
> 
> Please explain the case that this option is needed. What is 'custom
> kernel'? Isn't it 'over-design'?

The host lib makefile needs to know the kernel elf file to run though
ppu-embedspu.  I can use a default to hide it from the user. 

> (snip)
>> -libmars_la_CFLAGS = \
>> -	$(HOST_FLAGS)
>> -	-Wall \
>> -	-Wunused \
>> -	-Winline \
>> -	-Wredundant-decls \
>> -	-Wstrict-prototypes \
>> -	-Wmissing-prototypes \
>> -	-Wmissing-declarations
>> +libmars_la_SOURCES =                   \
>> + mars.c                                \
>> + mars_elf.c                            \
>> + mars_mutex.c                          \
>> + mars_workload_queue.c                 \
>> + mars_task.c                           \
>> + mars_task_barrier.c                   \
>> + mars_task_event_flag.c                \
>> + mars_task_queue.c                     \
>> + mars_task_semaphore.c                 \
>> + mars_task_signal.c
> (snip)
>> -libmars_la_SOURCES = \
>> -	mars.c \
>> -	mars_elf.c \
>> -	mars_mutex.c \
>> -	mars_workload_queue.c \
>> -	mars_task.c \
>> -	mars_task_barrier.c \
>> -	mars_task_event_flag.c \
>> -	mars_task_queue.c \
>> -	mars_task_semaphore.c \
>> -	mars_task_signal.c
> 
> Some of these are just indentation changes. Are there any strict rules
> of indentation of Makefile? Otherwise, I suggest keeping the original one.

These replace tabs with spaces.  I know of no rules.  I'm not sure how safe
tabs are to use between arguments, nor what kind of processing make does on
these.  It sounds like it could cause portability problems though.  I know
tabs in makefile conditionals will not work reliably:

if ABC
	"d=not seen!!"
endif

The extra spaces to justify the backslash could cause problems on
systems with limited command line length.  I think cygwin has a
very small limit (256 chars?), so I'll remove those.

-Geoff








More information about the cbe-oss-dev mailing list