1 # 2 # CDDL HEADER START 3 # 4 # The contents of this file are subject to the terms of the 5 # Common Development and Distribution License (the "License"). 6 # You may not use this file except in compliance with the License. 7 # 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 # Copyright 2010 Sun Microsystems, Inc. All rights reserved. 24 # Use is subject to license terms. 25 # 26 # Copyright 2019 OmniOS Community Edition (OmniOSce) Association. 27 # 28 29 # Don't generate separate sections for this module 30 pics/debugdata.o := XFFLAG= 31 32 # Since we use RTLD rather than DYNLIB, we must explicitly hook in ctfmerge. 33 $(RTLD) := CTFMERGE_POST = $(CTFMERGE_LIB) 34 35 pics/%.o: %.s 36 $(BUILD.s) 37 $(POST_PROCESS_O) 38 39 pics/%.o: $(CRTSRCS)/%.s 40 $(BUILD.s) 41 $(POST_PROCESS_O) 42 43 pics/%.o: %.c 44 $(COMPILE.c) -o $@ $< 45 $(POST_PROCESS_O) 46 47 pics/%.o: ../common/%.c 48 $(COMPILE.c) -o $@ $< 49 $(POST_PROCESS_O) 50 51 pics/%.o: $(VAR_AVLDIR)/%.c 52 $(COMPILE.c) -o $@ $< 53 $(POST_PROCESS_O) 54 55 pics/%.o: $(VAR_DTRDIR)/%.c 56 $(COMPILE.c) -o $@ $< 57 $(POST_PROCESS_O) 58 59 pics/%.o: $(SGSTOOLS)/common/%.c 60 $(COMPILE.c) -o $@ $< 61 $(POST_PROCESS_O) 62 63 pics/%.o: $(SRCBASE)/uts/$(PLAT)/krtld/%.c 64 $(COMPILE.c) -o $@ $< 65 $(POST_PROCESS_O) 66 67 pics/elfcap.o: $(ELFCAP)/elfcap.c 68 $(COMPILE.c) -o $@ $(ELFCAP)/elfcap.c 69 $(POST_PROCESS_O) 70 71 $(RTLD): pics $(PICS) $(CRTS) 72 $(LD_USE_PROTO)ld -o $@ -dy -G $(DYNFLAGS) $(CRTI) $(PICS) \ 73 $(LDLIBS) $(CRTN) 74 $(POST_PROCESS_SO) 75 76 delete: 77 -$(RM) $(RTLD) 78 79 $(ROOTFS_LIBDIR)/%: % 80 $(INS.file) 81 82 $(ETCLIBDIR)/%: % 83 $(INS.file) 84 85 include $(SRC)/lib/Makefile.targ 86 include $(SRC)/cmd/sgs/Makefile.targ 87 88 # Derived source and header files (messaging). 89 90 catalog: $(BLTMESG) 91 92 chkmsg := SGSMSGCHK=../common/rtld.chk.msg 93 94 chkmsg: $(SRCS) $(CHKSRCS) 95 sh $(CHKMSG) $(CHKMSGFLAGS) $(SRCS) $(CHKSRCS) 96 97 $(BLTDEFS) + \ 98 $(BLTDATA) : $(SGSMSGTARG) 99 $(SGSMSG) $(SGSMSGFLAGS2) $(SGSMSGTARG) 100 101 $(BLTMESG) : $(SGSMSGALL) 102 $(SGSMSG) $(SGSMSGFLAGS1) $(SGSMSGALL)