diff options
author | JozanLeClerc <JozanLeClerc@noemail.net> | 2020-11-18 16:32:27 +0000 |
---|---|---|
committer | JozanLeClerc <JozanLeClerc@noemail.net> | 2020-11-18 16:32:27 +0000 |
commit | fd93c3999636cbbc7f327a173ac1079c74c4bef5 (patch) | |
tree | aac8e4e6c212f263109f676b3ddaa77ff76c32fd /Makefile | |
parent | In progress (diff) | |
download | bsdsetsid-fd93c3999636cbbc7f327a173ac1079c74c4bef5.tar.gz bsdsetsid-fd93c3999636cbbc7f327a173ac1079c74c4bef5.tar.bz2 bsdsetsid-fd93c3999636cbbc7f327a173ac1079c74c4bef5.tar.xz bsdsetsid-fd93c3999636cbbc7f327a173ac1079c74c4bef5.tar.zst bsdsetsid-fd93c3999636cbbc7f327a173ac1079c74c4bef5.zip |
Finally Makefile is goodio
FossilOrigin-Name: ecd68fea526e3457a8f54a8d8ee81ae51d816446
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 30 |
1 files changed, 27 insertions, 3 deletions
@@ -26,12 +26,35 @@ SRCS := ${SRCS_DIR}c_bsdsetsid.S OBJS = ${SRCS:.S=.o} -AS := yasm -ASFLAGS := -felf64 +AS = yasm +ASFLAGS = -felf64 ASFLAGS += -pgas +ASFLAGS += -gdwarf2 + +CC = cc LD := ld LDFLAGS := -melf_x86_64 +LDFLAGS += --eh-frame-hdr +LDFLAGS += -dynamic-linker +LDFLAGS += /libexec/ld-elf.so.1 +LDFLAGS += --hash-style=both +LDFLAGS += --enable-new-dtags +LDPOST := /usr/lib/crt1.o +LDPOST += /usr/lib/crti.o +LDPOST += /usr/lib/crtbegin.o +LDPOST += -L/usr/lib +LDPOST += -lgcc +LDPOST += --as-needed +LDPOST += -lgcc_s +LDPOST += --no-as-needed +LDPOST += -lc +LDPOST += -lgcc +LDPOST += --as-needed +LDPOST += -lgcc_s +LDPOST += --no-as-needed +LDPOST += /usr/lib/crtend.o +LDPOST += /usr/lib/crtn.o NAME := bsdsetsid @@ -43,7 +66,8 @@ RM := rm -f ${AS} ${ASFLAGS} -o ${.TARGET} ${.IMPSRC} ${NAME}: ${OBJS} - ${LD} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} + ${LD} ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} ${LDPOST} + # ${CC} -v -o ${.TARGET} ${.ALLSRC} all: ${NAME} |