Changeset e0ba3e8 in rtems


Ignore:
Timestamp:
Jul 10, 2000, 7:23:38 PM (19 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
ebb0bb92
Parents:
256cbec
Message:

Patch rtems-rc-20000709-1.diff from Ralf Corsepius <corsepiu@…>
that addresses aspects of the targopts.h multilib related
issues.

Changes:

  • Move targopts.h to libbsp/include, because the current targopts.h actually is a per-BSP-header and therefore can not stay below exec/.
  • Introduce an autoheader generated header file (exec/score/include/rtems/score/cpuopts.h), which shall take per-cpu configuration options only.
  • Move all autoconf-detectable/configure specified per-cpu option-defines from targopts.h to cpuopts.h.
  • Add Makefiles to the libbsp/shared directory hierarchy.

Notes:

  • The new per-bsp targopts.h in libbsp includes the per-cpu cpuopts.h. This way, the new targopts.h is kept backward compatible to the old targopts.h and existing BSPs which (carelessly) include targopts.h (i386, ppc) should be kept working when using the multilib-disabled configuration scheme.
  • cpuopts.h is not yet complete, because the per-BSP make-targopts rules from custom/<BSP>.cfg files can not be applied to files below exec/ when building multilibs.
  • All files below exec/ should not include targopts.h anymore, but should include cpuopts.h instead. However, eliminating inclusion of targopts.h currently triggers further structural / header file inclusion related issues, because several ports apply BSP or CPU_MODEL specific defines from targopts.h below exec/
Files:
10 added
8 edited

Legend:

Unmodified
Added
Removed
  • c/src/exec/configure.in

    r256cbec re0ba3e8  
    6868AC_CONFIG_SUBDIRS(score/cpu/$RTEMS_CPU)
    6969
     70AM_CONFIG_HEADER(score/include/rtems/score/cpuopts-tmp.h)
     71
    7072# Explicitly list all Makefiles here
    7173AC_OUTPUT(
  • c/src/exec/score/include/rtems/score/.cvsignore

    r256cbec re0ba3e8  
    11Makefile
    22Makefile.in
     3stamp-h.in
     4cpuopts-tmp.h.in
  • c/src/exec/score/include/rtems/score/Makefile.am

    r256cbec re0ba3e8  
    1515    priority.h stack.h states.h sysstate.h thread.h threadq.h tod.h tqdata.h \
    1616    userext.h watchdog.h wkspace.h
    17 TARGOPTS = targopts.h
    1817
    1918if HAS_MP
    20 H_FILES = $(STD_H_FILES) $(TARGOPTS) $(MP_H_FILES)
     19H_FILES = $(STD_H_FILES) $(MP_H_FILES) cpuopts.h
    2120else
    22 H_FILES = $(STD_H_FILES) $(TARGOPTS)
     21H_FILES = $(STD_H_FILES) cpuopts.h
    2322endif
    2423
     
    3231        $(INSTALL_DATA) $< $@
    3332
    34 CLEANFILES += $(TARGOPTS)
    35 
    36 # Until RTEMS_CPU is removed from all the make configuration files,
    37 # this will need to be here to transform hppa1.1 into hppa1_1 to
    38 # make it a valid cpp symbol.  At some point in the near future,
    39 # targopts.h should not define RTEMS_CPU.  As best I can tell,
    40 # gcc cpp predefines eliminate the need for RTEMS_CPU_MODEL
    41 # on some families but not on others.  For example, the i386
    42 # family does not give us enough information from the predefines.
    43 RTEMS_CPU_DEFINED = $(subst .,_,$(RTEMS_CPU))
    44 
    45 # make the target dependent options file
    46 $(TARGOPTS):
    47         @echo "/* target board dependent options file */"       >$@
     33# make the cpu dependent options file
     34# FIXME: We are exporting a config-header here, which is a bad idea in
     35# general
     36cpuopts.h: cpuopts-tmp.h
     37        @echo "/* target cpu dependent options file */"        >$@
    4838        @echo "/* automatically generated -- DO NOT EDIT!! */" >>$@
    4939        @echo                                                  >>$@
    50         @echo "#ifndef __TARGET_OPTIONS_h"                     >>$@
    51         @echo "#define __TARGET_OPTIONS_h"                     >>$@
     40        @echo "#ifndef __CPU_OPTIONS_h"                        >>$@
     41        @echo "#define __CPU_OPTIONS_h"                        >>$@
    5242        @echo                                                  >>$@
    53         @echo "#ifdef $(RTEMS_CPU_DEFINED)"                    >>$@
    54         @echo "#undef $(RTEMS_CPU_DEFINED)"                    >>$@
    55         @echo "#endif"                                         >>$@
    56         @echo "#define $(RTEMS_CPU_DEFINED) 1"                 >>$@
    57         @echo                                                  >>$@
    58         @echo "#ifdef $(RTEMS_CPU_MODEL)"                      >>$@
    59         @echo "#undef $(RTEMS_CPU_MODEL)"                      >>$@
    60         @echo "#endif"                                         >>$@
    61         @echo "#define $(RTEMS_CPU_MODEL) 1"                   >>$@
    62         @echo                                                  >>$@
    63         @echo "#ifdef @RTEMS_BSP@"                            >>$@
    64         @echo "#undef @RTEMS_BSP@"                            >>$@
    65         @echo "#endif"                                         >>$@
    66         @echo "#define @RTEMS_BSP@ 1"                         >>$@
    67         @echo                                                  >>$@
    68         @$(make-target-options)
    69         @if test "$(RTEMS_USE_MACROS)" = "yes"; then \
    70         echo "#define USE_MACROS 1"             >>$@; \
    71         else \
    72         echo "#define USE_INLINES 1"            >>$@; \
    73         fi
    74         @if test "$(HAS_MP)" = "yes"; then \
    75         echo "#define RTEMS_MULTIPROCESSING 1"  >>$@; \
    76         fi
    77         @if test "$(HAS_POSIX_API)" = "yes"; then \
    78         echo "#define RTEMS_POSIX_API 1"        >>$@; \
    79         fi
    80         @if test "$(HAS_ITRON_API)" = "yes"; then \
    81         echo "#define RTEMS_ITRON_API 1"        >>$@; \
    82         fi
    83         @if test "$(RTEMS_USE_NEWLIB)" = "yes"; then    \
    84         echo "#define RTEMS_NEWLIB 1"           >>$@;   \
    85         echo "#define MALLOC_PROVIDED 1"        >>$@;   \
    86         fi
     43        @cat cpuopts-tmp.h                                     >>$@
    8744        @echo                                                  >>$@
    8845        @echo "#endif"                                         >>$@
  • c/src/exec/score/include/rtems/system.h

    r256cbec re0ba3e8  
    2828 */
    2929
     30/*
     31 * FIXME: Instead of targopts.h, cpuopts.h should be included here.
     32 * #include <rtems/score/cpuopts.h>
     33 */
    3034#include <rtems/score/targopts.h>
    3135
  • c/src/lib/libbsp/Makefile.am

    r256cbec re0ba3e8  
    1212# into that directory.
    1313
    14 SUBDIRS += shmdr @RTEMS_LIBBSP_CPU_SUBDIR@
     14SUBDIRS += include shared shmdr @RTEMS_LIBBSP_CPU_SUBDIR@
    1515
    1616EXTRA_DIST = MERGE.PROCEDURE bsp.am
  • c/src/lib/libbsp/configure.in

    r256cbec re0ba3e8  
    4343
    4444# Explicitly list all Makefiles here
    45 AC_OUTPUT( 
     45AC_OUTPUT(
    4646Makefile
    47 shmdr/Makefile)
     47shmdr/Makefile
     48shared/Makefile
     49shared/include/Makefile
     50include/Makefile
     51include/rtems/Makefile
     52include/rtems/score/Makefile
     53)
  • cpukit/score/include/rtems/score/.cvsignore

    r256cbec re0ba3e8  
    11Makefile
    22Makefile.in
     3stamp-h.in
     4cpuopts-tmp.h.in
  • cpukit/score/include/rtems/system.h

    r256cbec re0ba3e8  
    2828 */
    2929
     30/*
     31 * FIXME: Instead of targopts.h, cpuopts.h should be included here.
     32 * #include <rtems/score/cpuopts.h>
     33 */
    3034#include <rtems/score/targopts.h>
    3135
Note: See TracChangeset for help on using the changeset viewer.