Print this page
crt: Need a position-independent CRT for PIE
- Implement the greatest possible part of the crt1 in C
- Implement SPARC versions of the ASM sections of crt1
- Build crt1 position-independently, minor ASM updates to be position
  independent
- Implement crt1 with the hook expected by modern GCC to support
  profiling, make gcrt1 a symlink for source compatibility (older GCC
  initializes profiling at firsnt use of _mcount if necessary, so
  doesn't need the gcrt)
- Split the CRT out of developer/library/lint into a separate c-runtime package

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/libc/Makefile.targ
          +++ new/usr/src/lib/libc/Makefile.targ
↓ open down ↓ 257 lines elided ↑ open up ↑
 258  258          $(POST_PROCESS_O)
 259  259  
 260  260  pics/%.o: $(LIBCBASE)/../$(MACH)/unwind/%.s
 261  261          $(BUILD.s)
 262  262          $(POST_PROCESS_O)
 263  263  
 264  264  pics/%.o: $(LIBCBASE)/../port/sys/%.c
 265  265          $(COMPILE.c) -o $@ $<
 266  266          $(POST_PROCESS_O)
 267  267  
 268      -pics/%.o: $(LIBCBASE)/../../common/common/%.c
      268 +pics/%.o: $(LIBCBASE)/../../crt/common/%.c
 269  269          $(COMPILE.c) -o $@ $<
 270  270          $(POST_PROCESS_O)
 271  271  
 272  272  pics/%.o: $(LIBCBASE)/$(CRTSRCS)/%.s
 273  273          $(BUILD.s)
 274  274          $(POST_PROCESS_O)
 275  275  
 276  276  # $(SRC)/common rules
 277  277  pics/%.o: $(SRC)/common/atomic/$(TARGETMACH)/%.s
 278  278          $(BUILD.s)
↓ open down ↓ 33 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX