Print this page
m


  24 # Copyright 2019 Joyent, Inc.
  25 # Copyright 2017 Nexenta Systems, Inc.
  26 #
  27 
  28 #
  29 #       This Makefile defines all file modules and build rules for the
  30 # directory uts/intel and its children. These are the source files which
  31 # are specific to the intel processor.
  32 #
  33 #       The following two-level ordering must be maintained in this file.
  34 #         Lines are sorted first in order of decreasing specificity based on
  35 #         the first directory component.  That is, sun4u rules come before
  36 #         sparc rules come before common rules.
  37 #
  38 #         Lines whose initial directory components are equal are sorted
  39 #         alphabetically by the remaining components.
  40 
  41 #
  42 # Need a way to distinguish between the ia32 and amd64 subdirs.
  43 #
  44 SUBARCH_DIR_32 = ia32
  45 SUBARCH_DIR_64 = amd64
  46 SUBARCH_DIR     = $(SUBARCH_DIR_$(CLASS))
  47 
  48 #
  49 #       Section 1a: C object build rules
  50 #
  51 $(OBJS_DIR)/%.o:                $(SRC)/common/fs/%.c
  52         $(COMPILE.c) -o $@ $<
  53         $(CTFCONVERT_O)
  54 
  55 $(OBJS_DIR)/%.o:                $(UTSBASE)/common/io/power/%.c
  56         $(COMPILE.c) -o $@ $<
  57         $(CTFCONVERT_O)
  58 
  59 $(OBJS_DIR)/%.o:                $(SRC)/common/util/i386/%.s
  60         $(COMPILE.s) -o $@ $<
  61 
  62 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/brand/sn1/%.s
  63         $(COMPILE.s) -o $@ $<
  64 
  65 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/brand/solaris10/%.s
  66         $(COMPILE.s) -o $@ $<
  67 
  68 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/dtrace/%.c
  69         $(COMPILE.c) -o $@ $<
  70         $(CTFCONVERT_O)
  71 
  72 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/dtrace/%.s
  73         $(COMPILE.s) -o $@ $<
  74 
  75 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/fs/proc/%.c
  76         $(COMPILE.c) -o $@ $<
  77         $(CTFCONVERT_O)
  78 
  79 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/ia32/ml/%.s
  80         $(COMPILE.s) -o $@ $<
  81 


 291 
 292 $(OBJS_DIR)/%.o:        $(UTSBASE)/intel/$(SUBARCH_DIR)/krtld/%.c
 293         $(COMPILE.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) -o $@ $<
 294         $(CTFCONVERT_O)
 295 
 296 #
 297 # _DBOOT indicates that krtld is called from a dboot ELF section
 298 #
 299 $(OBJS_DIR)/kobj.o              := CPPFLAGS += -D_DBOOT
 300 
 301 $(DBOOT_OBJS_DIR)/%.o:          $(UTSBASE)/intel/ia32/ml/%.s
 302         $(DBOOT_AS) -P -D_ASM $(DBOOT_DEFS) $(DBOOT_AS_INCL) -o $@ $<
 303 
 304 
 305 $(OBJS_DIR)/%.o:        $(UTSBASE)/intel/$(SUBARCH_DIR)/krtld/%.s
 306         $(COMPILE.s) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) -o $@ $<
 307 
 308 $(OBJS_DIR)/%.o:        $(SRC)/common/util/$(SUBARCH_DIR)/%.c
 309         $(COMPILE.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) -o $@ $<
 310         $(CTFCONVERT_O)
 311 
 312 
 313 #
 314 #       Section 1b: Lint `object' build rules.
 315 #
 316 $(LINTS_DIR)/%.ln:              $(SRC)/common/fs/%.c
 317         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 318 
 319 $(LINTS_DIR)/%.ln:              $(SRC)/common/util/i386/%.s
 320         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 321 
 322 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/brand/sn1/%.s
 323         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 324 
 325 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/brand/solaris10/%.s
 326         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 327 
 328 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/dtrace/%.c
 329         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 330 
 331 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/dtrace/%.s
 332         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 333 
 334 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/zfs/%.c
 335         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 336 
 337 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/fs/proc/%.c
 338         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 339 
 340 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/ia32/ml/%.s
 341         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 342 
 343 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/ia32/os/%.c
 344         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 345 
 346 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/ia32/promif/%.c
 347         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 348 
 349 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/ia32/syscall/%.c
 350         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 351 
 352 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/%.c
 353         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 354 
 355 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/acpica/%.s
 356         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 357 
 358 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/acpica/%.c
 359         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 360 
 361 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/events/%.c
 362         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 363 
 364 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/hardware/%.c
 365         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 366 
 367 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/dispatcher/%.c
 368         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 369 
 370 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/executer/%.c
 371         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 372 
 373 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/parser/%.c
 374         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 375 
 376 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/namespace/%.c
 377         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 378 
 379 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/resources/%.c
 380         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 381 
 382 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/tables/%.c
 383         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 384 
 385 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/utilities/%.c
 386         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 387 
 388 $(LINTS_DIR)/%.ln:              $(SRC)/common/acpica/disassembler/%.c
 389         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 390 
 391 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/amd8111s/%.c
 392         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 393 
 394 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/amr/%.c
 395         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 396 
 397 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/scsi/adapters/arcmsr/%.c
 398         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 399 
 400 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/hotplug/pcicfg/%.c
 401         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 402 
 403 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/hotplug/pci/%.c
 404         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 405 
 406 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/intel_nb5000/%.c
 407         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 408 
 409 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/intel_nhm/%.c
 410         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 411 
 412 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/ipmi/%.c
 413         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 414 
 415 $(LINTS_DIR)/%.ln:              $(SRC)/common/mc/mc-amd/%.c
 416         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 417 
 418 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/mc-amd/%.c
 419         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 420 
 421 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/pci/%.c
 422         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 423 
 424 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/pciex/%.c
 425         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 426 
 427 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/dktp/controller/ata/%.c
 428         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 429 
 430 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/dktp/dcdev/%.c
 431         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 432 
 433 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/dktp/disk/%.c
 434         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 435 
 436 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/dktp/drvobj/%.c
 437         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 438 
 439 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/dktp/hba/ghd/%.c
 440         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 441 
 442 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/dnet/%.c
 443         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 444 
 445 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/scsi/targets/%.c
 446         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 447 
 448 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/vgatext/%.c
 449         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 450 
 451 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/vmxnet3s/%.c
 452         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 453 
 454 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/io/scsi/adapters/pvscsi/%.c
 455         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 456 
 457 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/os/%.c
 458         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 459 
 460 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/pcbe/%.c
 461         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 462 
 463 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/promif/%.c
 464         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 465 
 466 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/syscall/%.c
 467         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 468 
 469 $(LINTS_DIR)/%.ln:              $(UTSBASE)/common/os/%.c
 470         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 471 
 472 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/kdi/%.c
 473         @($(LHEAD) $(LINT.c) $< $(LTAIL))
 474 
 475 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/kdi/%.s
 476         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 477 
 478 $(LINTS_DIR)/%.ln:              $(UTSBASE)/intel/nskern/%.s
 479         @($(LHEAD) $(LINT.s) $< $(LTAIL))
 480 
 481 #
 482 # krtld lints
 483 #
 484 $(LINTS_DIR)/%.ln:              $(UTSBASE)/common/krtld/%.c
 485         @($(LHEAD) $(LINT.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) $< $(LTAIL))
 486 
 487 $(LINTS_DIR)/%.ln:      $(UTSBASE)/intel/$(SUBARCH_DIR)/krtld/%.c
 488         @($(LHEAD) $(LINT.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) $< $(LTAIL))
 489 
 490 $(LINTS_DIR)/%.ln:      $(UTSBASE)/intel/$(SUBARCH_DIR)/krtld/%.s
 491         @($(LHEAD) $(LINT.s) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) $< $(LTAIL))
 492 
 493 $(LINTS_DIR)/%.ln:      $(SRC)/common/util/$(SUBARCH_DIR)/%.c
 494         @($(LHEAD) $(LINT.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) $< $(LTAIL))
 495 
 496 $(OBJS_DIR)/kobj.ln             := CPPFLAGS += -D_DBOOT


  24 # Copyright 2019 Joyent, Inc.
  25 # Copyright 2017 Nexenta Systems, Inc.
  26 #
  27 
  28 #
  29 #       This Makefile defines all file modules and build rules for the
  30 # directory uts/intel and its children. These are the source files which
  31 # are specific to the intel processor.
  32 #
  33 #       The following two-level ordering must be maintained in this file.
  34 #         Lines are sorted first in order of decreasing specificity based on
  35 #         the first directory component.  That is, sun4u rules come before
  36 #         sparc rules come before common rules.
  37 #
  38 #         Lines whose initial directory components are equal are sorted
  39 #         alphabetically by the remaining components.
  40 
  41 #
  42 # Need a way to distinguish between the ia32 and amd64 subdirs.
  43 #
  44 SUBARCH_DIR = amd64


  45 
  46 #
  47 #       Section 1a: C object build rules
  48 #
  49 $(OBJS_DIR)/%.o:                $(SRC)/common/fs/%.c
  50         $(COMPILE.c) -o $@ $<
  51         $(CTFCONVERT_O)
  52 
  53 $(OBJS_DIR)/%.o:                $(UTSBASE)/common/io/power/%.c
  54         $(COMPILE.c) -o $@ $<
  55         $(CTFCONVERT_O)
  56 



  57 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/brand/sn1/%.s
  58         $(COMPILE.s) -o $@ $<
  59 
  60 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/brand/solaris10/%.s
  61         $(COMPILE.s) -o $@ $<
  62 
  63 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/dtrace/%.c
  64         $(COMPILE.c) -o $@ $<
  65         $(CTFCONVERT_O)
  66 
  67 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/dtrace/%.s
  68         $(COMPILE.s) -o $@ $<
  69 
  70 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/fs/proc/%.c
  71         $(COMPILE.c) -o $@ $<
  72         $(CTFCONVERT_O)
  73 
  74 $(OBJS_DIR)/%.o:                $(UTSBASE)/intel/ia32/ml/%.s
  75         $(COMPILE.s) -o $@ $<
  76 


 286 
 287 $(OBJS_DIR)/%.o:        $(UTSBASE)/intel/$(SUBARCH_DIR)/krtld/%.c
 288         $(COMPILE.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) -o $@ $<
 289         $(CTFCONVERT_O)
 290 
 291 #
 292 # _DBOOT indicates that krtld is called from a dboot ELF section
 293 #
 294 $(OBJS_DIR)/kobj.o              := CPPFLAGS += -D_DBOOT
 295 
 296 $(DBOOT_OBJS_DIR)/%.o:          $(UTSBASE)/intel/ia32/ml/%.s
 297         $(DBOOT_AS) -P -D_ASM $(DBOOT_DEFS) $(DBOOT_AS_INCL) -o $@ $<
 298 
 299 
 300 $(OBJS_DIR)/%.o:        $(UTSBASE)/intel/$(SUBARCH_DIR)/krtld/%.s
 301         $(COMPILE.s) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) -o $@ $<
 302 
 303 $(OBJS_DIR)/%.o:        $(SRC)/common/util/$(SUBARCH_DIR)/%.c
 304         $(COMPILE.c) $(KRTLD_INC_PATH) $(KRTLD_CPPFLAGS) -o $@ $<
 305         $(CTFCONVERT_O)