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 


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


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