Print this page
remove inlines,some other files


   8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9 # or http://www.opensolaris.org/os/licensing.
  10 # See the License for the specific language governing permissions
  11 # and limitations under the License.
  12 #
  13 # When distributing Covered Code, include this CDDL HEADER in each
  14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15 # If applicable, add the following below this CDDL HEADER, with the
  16 # fields enclosed by brackets "[]" replaced with your own identifying
  17 # information: Portions Copyright [yyyy] [name of copyright owner]
  18 #
  19 # CDDL HEADER END
  20 #
  21 
  22 #
  23 # uts/i86pc/Makefile.i86pc
  24 #
  25 # Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
  26 # Copyright (c) 2013 Andrew Stormont.  All rights reserved.
  27 # Copyright 2019 OmniOS Community Edition (OmniOSce) Association.

  28 #
  29 #
  30 #       This makefile contains the common definitions for the i86pc unix
  31 #       and all i86pc implementation architecture dependent modules.
  32 #
  33 
  34 #
  35 #       Machine type (implementation architecture):
  36 #
  37 PLATFORM         = i86pc
  38 
  39 #
  40 #       uname -m value
  41 #
  42 UNAME_M         = $(PLATFORM)
  43 
  44 #
  45 # Definitions for the platform-specific /platform directories.
  46 #
  47 # IMPLEMENTATIONS is used to designate i86pc machines which have


  81 #       interfaces.)
  82 #
  83 include $(UTSBASE)/$(PLATFORM)/Makefile.files
  84 include $(UTSBASE)/intel/Makefile.files
  85 include $(UTSBASE)/common/Makefile.files
  86 
  87 #
  88 #       Include machine independent rules. Note that this does not imply
  89 #       that the resulting module from rules in Makefile.uts is machine
  90 #       independent. Only that the build rules are machine independent.
  91 #
  92 include $(UTSBASE)/Makefile.uts
  93 
  94 #
  95 #       Define supported builds
  96 #
  97 DEF_BUILDS              = $(DEF_BUILDS64)
  98 ALL_BUILDS              = $(ALL_BUILDS64)
  99 
 100 #
 101 #       x86 or amd64 inline templates
 102 #
 103 INLINES_32              = $(UTSBASE)/intel/ia32/ml/ia32.il \
 104                           $(UTSBASE)/$(PLATFORM)/ml/ia32.il
 105 INLINES_64              = $(UTSBASE)/intel/amd64/ml/amd64.il \
 106                           $(UTSBASE)/$(PLATFORM)/ml/amd64.il
 107 INLINES                 += $(INLINES_$(CLASS))
 108 
 109 #
 110 #       kernel-specific optimizations; override default in Makefile.master
 111 #
 112 
 113 CFLAGS_XARCH_32         = $(i386_CFLAGS)
 114 CFLAGS_XARCH_64         = $(amd64_CFLAGS)
 115 CFLAGS_XARCH            = $(CFLAGS_XARCH_$(CLASS))
 116 
 117 COPTFLAG_32             = $(COPTFLAG)
 118 COPTFLAG_64             = $(COPTFLAG64)
 119 COPTIMIZE               = $(COPTFLAG_$(CLASS))
 120 
 121 CFLAGS                  = $(CFLAGS_XARCH)
 122 CFLAGS                  += $(COPTIMIZE)
 123 CFLAGS                  += $(INLINES) -D_ASM_INLINES
 124 CFLAGS                  += $(CCMODE)
 125 CFLAGS                  += $(SPACEFLAG)
 126 CFLAGS                  += $(CCUNBOUND)
 127 CFLAGS                  += $(CFLAGS_uts)
 128 CFLAGS                  += -xstrconst
 129 
 130 ASFLAGS_XARCH_32        = $(i386_ASFLAGS)
 131 ASFLAGS_XARCH_64        = $(amd64_ASFLAGS)
 132 ASFLAGS_XARCH           = $(ASFLAGS_XARCH_$(CLASS))
 133 
 134 ASFLAGS                 += $(ASFLAGS_XARCH)
 135 
 136 AS_INC_PATH             += -I$(DSF_DIR)/$(OBJS_DIR)
 137 
 138 #
 139 #       The following must be defined for all implementations:
 140 #
 141 #       MAPFILE:        ld mapfile for the build of kernel/unix.
 142 #       MODSTUBS:       Module stubs source file.
 143 #       GENASSYM_SRC:   genassym.c
 144 #
 145 MAPFILE          = $(UTSBASE)/$(PLATFORM)/conf/Mapfile
 146 MODSTUBS         = $(UTSBASE)/intel/ia32/ml/modstubs.s
 147 GENASSYM_SRC     = $(UTSBASE)/$(PLATFORM)/ml/genassym.c
 148 OFFSETS_SRC      = $(UTSBASE)/$(PLATFORM)/ml/offsets.in
 149 PLATFORM_OFFSETS_32     = $(UTSBASE)/$(PLATFORM)/ml/mach_offsets.in
 150 PLATFORM_OFFSETS_64     = $(UTSBASE)/intel/amd64/ml/mach_offsets.in
 151 PLATFORM_OFFSETS_SRC    = $(PLATFORM_OFFSETS_$(CLASS))
 152 KDI_OFFSETS_SRC  = $(UTSBASE)/intel/kdi/kdi_offsets.in
 153 
 154 #
 155 #       Define the actual specific platforms
 156 #
 157 MACHINE_DEFS     = -D$(PLATFORM) -D_MACHDEP
 158 
 159 #
 160 #       Software workarounds for hardware "features"
 161 #
 162 
 163 include $(UTSBASE)/$(PLATFORM)/Makefile.workarounds
 164 
 165 #
 166 #       Debugging level
 167 #
 168 #       Special knowledge of which special debugging options effect which
 169 #       file is used to optimize the build if these flags are changed.
 170 #
 171 #       XXX: The above could possibly be done for more flags and files, but
 172 #            is left as an experiment to the interested reader. Be forewarned,
 173 #            that excessive use could lead to maintenance difficulties.
 174 #
 175 DEBUG_DEFS_OBJ32        =
 176 DEBUG_DEFS_DBG32        = -DDEBUG
 177 DEBUG_DEFS_OBJ64        =
 178 DEBUG_DEFS_DBG64        = -DDEBUG
 179 DEBUG_DEFS              = $(DEBUG_DEFS_$(BUILD_TYPE))
 180 
 181 DEBUG_COND_OBJ32        = $(POUND_SIGN)
 182 DEBUG_COND_DBG32        =
 183 DEBUG_COND_OBJ64        = $(POUND_SIGN)
 184 DEBUG_COND_DBG64        =
 185 IF_DEBUG_OBJ            = $(DEBUG_COND_$(BUILD_TYPE))$(OBJS_DIR)/
 186 
 187 $(IF_DEBUG_OBJ)trap.o           := DEBUG_DEFS += -DTRAPDEBUG -DTRAPTRACE
 188 $(IF_DEBUG_OBJ)syscall_asm.o    := DEBUG_DEFS += -DSYSCALLTRACE -DTRAPTRACE
 189 $(IF_DEBUG_OBJ)syscall_asm_amd64.o := DEBUG_DEFS += -DSYSCALLTRACE -DTRAPTRACE
 190 $(IF_DEBUG_OBJ)fast_trap_asm.o  := DEBUG_DEFS += -DTRAPTRACE
 191 $(IF_DEBUG_OBJ)interrupt.o      := DEBUG_DEFS += -DTRAPTRACE
 192 $(IF_DEBUG_OBJ)intr.o           := DEBUG_DEFS += -DTRAPTRACE
 193 $(IF_DEBUG_OBJ)locore.o         := DEBUG_DEFS += -DTRAPTRACE
 194 $(IF_DEBUG_OBJ)mp_startup.o     := DEBUG_DEFS += -DTRAPTRACE
 195 $(IF_DEBUG_OBJ)machdep.o        := DEBUG_DEFS += -DTRAPTRACE
 196 $(IF_DEBUG_OBJ)exception.o      := DEBUG_DEFS += -DTRAPTRACE
 197 $(IF_DEBUG_OBJ)x_call.o         := DEBUG_DEFS += -DTRAPTRACE
 198 $(IF_DEBUG_OBJ)mp_call.o        := DEBUG_DEFS += -DTRAPTRACE
 199 $(IF_DEBUG_OBJ)cbe.o            := DEBUG_DEFS += -DTRAPTRACE
 200 
 201 #
 202 #       Collect the preprocessor definitions to be associated with *all*
 203 #       files.
 204 #
 205 ALL_DEFS         = $(MACHINE_DEFS) $(WORKAROUND_DEFS) $(DEBUG_DEFS) \
 206                    $(OPTION_DEFS)
 207 GENASSYM_DEFS    = $(MACHINE_DEFS) $(OPTION_DEFS) \
 208                         -_gcc=-fno-eliminate-unused-debug-symbols \
 209                         -_gcc=-fno-eliminate-unused-debug-types




   8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9 # or http://www.opensolaris.org/os/licensing.
  10 # See the License for the specific language governing permissions
  11 # and limitations under the License.
  12 #
  13 # When distributing Covered Code, include this CDDL HEADER in each
  14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15 # If applicable, add the following below this CDDL HEADER, with the
  16 # fields enclosed by brackets "[]" replaced with your own identifying
  17 # information: Portions Copyright [yyyy] [name of copyright owner]
  18 #
  19 # CDDL HEADER END
  20 #
  21 
  22 #
  23 # uts/i86pc/Makefile.i86pc
  24 #
  25 # Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
  26 # Copyright (c) 2013 Andrew Stormont.  All rights reserved.
  27 # Copyright 2019 OmniOS Community Edition (OmniOSce) Association.
  28 # Copyright 2019 Joyent, Inc.
  29 #
  30 #
  31 #       This makefile contains the common definitions for the i86pc unix
  32 #       and all i86pc implementation architecture dependent modules.
  33 #
  34 
  35 #
  36 #       Machine type (implementation architecture):
  37 #
  38 PLATFORM         = i86pc
  39 
  40 #
  41 #       uname -m value
  42 #
  43 UNAME_M         = $(PLATFORM)
  44 
  45 #
  46 # Definitions for the platform-specific /platform directories.
  47 #
  48 # IMPLEMENTATIONS is used to designate i86pc machines which have


  82 #       interfaces.)
  83 #
  84 include $(UTSBASE)/$(PLATFORM)/Makefile.files
  85 include $(UTSBASE)/intel/Makefile.files
  86 include $(UTSBASE)/common/Makefile.files
  87 
  88 #
  89 #       Include machine independent rules. Note that this does not imply
  90 #       that the resulting module from rules in Makefile.uts is machine
  91 #       independent. Only that the build rules are machine independent.
  92 #
  93 include $(UTSBASE)/Makefile.uts
  94 
  95 #
  96 #       Define supported builds
  97 #
  98 DEF_BUILDS              = $(DEF_BUILDS64)
  99 ALL_BUILDS              = $(ALL_BUILDS64)
 100 
 101 #









 102 #       kernel-specific optimizations; override default in Makefile.master
 103 #
 104 
 105 CFLAGS_XARCH_32         = $(i386_CFLAGS)
 106 CFLAGS_XARCH_64         = $(amd64_CFLAGS)
 107 CFLAGS_XARCH            = $(CFLAGS_XARCH_$(CLASS))
 108 
 109 COPTFLAG_32             = $(COPTFLAG)
 110 COPTFLAG_64             = $(COPTFLAG64)
 111 COPTIMIZE               = $(COPTFLAG_$(CLASS))
 112 
 113 CFLAGS                  = $(CFLAGS_XARCH)
 114 CFLAGS                  += $(COPTIMIZE)
 115 CFLAGS                  += -D_ASM_INLINES
 116 CFLAGS                  += $(CCMODE)
 117 CFLAGS                  += $(SPACEFLAG)
 118 CFLAGS                  += $(CCUNBOUND)
 119 CFLAGS                  += $(CFLAGS_uts)
 120 CFLAGS                  += -xstrconst
 121 
 122 ASFLAGS_XARCH_32        = $(i386_ASFLAGS)
 123 ASFLAGS_XARCH_64        = $(amd64_ASFLAGS)
 124 ASFLAGS_XARCH           = $(ASFLAGS_XARCH_$(CLASS))
 125 
 126 ASFLAGS                 += $(ASFLAGS_XARCH)
 127 
 128 AS_INC_PATH             += -I$(DSF_DIR)/$(OBJS_DIR)
 129 
 130 #
 131 #       The following must be defined for all implementations:
 132 #
 133 #       MAPFILE:        ld mapfile for the build of kernel/unix.
 134 #       MODSTUBS:       Module stubs source file.
 135 #       GENASSYM_SRC:   genassym.c
 136 #
 137 MAPFILE          = $(UTSBASE)/$(PLATFORM)/conf/Mapfile
 138 MODSTUBS         = $(UTSBASE)/intel/ia32/ml/modstubs.s
 139 GENASSYM_SRC     = $(UTSBASE)/$(PLATFORM)/ml/genassym.c
 140 OFFSETS_SRC      = $(UTSBASE)/$(PLATFORM)/ml/offsets.in
 141 PLATFORM_OFFSETS_SRC    = $(UTSBASE)/intel/amd64/ml/mach_offsets.in


 142 KDI_OFFSETS_SRC  = $(UTSBASE)/intel/kdi/kdi_offsets.in
 143 
 144 #
 145 #       Define the actual specific platforms
 146 #
 147 MACHINE_DEFS     = -D$(PLATFORM) -D_MACHDEP
 148 
 149 #
 150 #       Software workarounds for hardware "features"
 151 #
 152 
 153 include $(UTSBASE)/$(PLATFORM)/Makefile.workarounds
 154 
 155 #
 156 #       Debugging level
 157 #
 158 #       Special knowledge of which special debugging options effect which
 159 #       file is used to optimize the build if these flags are changed.
 160 #
 161 #       XXX: The above could possibly be done for more flags and files, but
 162 #            is left as an experiment to the interested reader. Be forewarned,
 163 #            that excessive use could lead to maintenance difficulties.
 164 #
 165 DEBUG_DEFS_OBJ32        =
 166 DEBUG_DEFS_DBG32        = -DDEBUG
 167 DEBUG_DEFS_OBJ64        =
 168 DEBUG_DEFS_DBG64        = -DDEBUG
 169 DEBUG_DEFS              = $(DEBUG_DEFS_$(BUILD_TYPE))
 170 
 171 DEBUG_COND_OBJ32        = $(POUND_SIGN)
 172 DEBUG_COND_DBG32        =
 173 DEBUG_COND_OBJ64        = $(POUND_SIGN)
 174 DEBUG_COND_DBG64        =
 175 IF_DEBUG_OBJ            = $(DEBUG_COND_$(BUILD_TYPE))$(OBJS_DIR)/
 176 
 177 $(IF_DEBUG_OBJ)trap.o           := DEBUG_DEFS += -DTRAPDEBUG -DTRAPTRACE
 178 $(IF_DEBUG_OBJ)syscall_asm.o    := DEBUG_DEFS += -DSYSCALLTRACE -DTRAPTRACE

 179 $(IF_DEBUG_OBJ)fast_trap_asm.o  := DEBUG_DEFS += -DTRAPTRACE
 180 $(IF_DEBUG_OBJ)interrupt.o      := DEBUG_DEFS += -DTRAPTRACE
 181 $(IF_DEBUG_OBJ)intr.o           := DEBUG_DEFS += -DTRAPTRACE
 182 $(IF_DEBUG_OBJ)locore.o         := DEBUG_DEFS += -DTRAPTRACE
 183 $(IF_DEBUG_OBJ)mp_startup.o     := DEBUG_DEFS += -DTRAPTRACE
 184 $(IF_DEBUG_OBJ)machdep.o        := DEBUG_DEFS += -DTRAPTRACE
 185 $(IF_DEBUG_OBJ)exception.o      := DEBUG_DEFS += -DTRAPTRACE
 186 $(IF_DEBUG_OBJ)x_call.o         := DEBUG_DEFS += -DTRAPTRACE
 187 $(IF_DEBUG_OBJ)mp_call.o        := DEBUG_DEFS += -DTRAPTRACE
 188 $(IF_DEBUG_OBJ)cbe.o            := DEBUG_DEFS += -DTRAPTRACE
 189 
 190 #
 191 #       Collect the preprocessor definitions to be associated with *all*
 192 #       files.
 193 #
 194 ALL_DEFS         = $(MACHINE_DEFS) $(WORKAROUND_DEFS) $(DEBUG_DEFS) \
 195                    $(OPTION_DEFS)
 196 GENASSYM_DEFS    = $(MACHINE_DEFS) $(OPTION_DEFS) \
 197                         -_gcc=-fno-eliminate-unused-debug-symbols \
 198                         -_gcc=-fno-eliminate-unused-debug-types