From 5740a2b62d4cff6a434d2ec5c250e492215d5402 Mon Sep 17 00:00:00 2001 From: Ruslan Ermilov Date: Sat, 18 Mar 2006 21:37:05 +0000 Subject: [PATCH] Convert NO_PROFILE and NO_LIB32 to new style. --- Makefile.inc1 | 11 +++++------ gnu/lib/libg2c/Makefile | 4 +++- gnu/lib/libgcc/Makefile | 5 +++-- gnu/lib/libgcov/Makefile | 5 +++-- lib/libc_r/Makefile | 2 +- lib/libncurses/Makefile | 2 +- lib/libpam/modules/Makefile.inc | 2 +- lib/libthr/Makefile | 5 ++++- lib/ncurses/ncurses/Makefile | 2 +- release/Makefile | 4 ++-- share/mk/bsd.lib.mk | 6 +++--- usr.bin/lex/lib/Makefile | 4 +++- 12 files changed, 30 insertions(+), 22 deletions(-) diff --git a/Makefile.inc1 b/Makefile.inc1 index f7d2ec507fd0..c323d48209e9 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -4,7 +4,6 @@ # Make command line options: # -DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir # -DNO_CLEAN do not clean at all -# -DNO_PROFILE do not build profiled libraries # -DNO_SHARE do not go into share subdir # -DNO_KERNELCONFIG do not run config in ${MAKE} buildkernel # -DNO_KERNELCLEAN do not run ${MAKE} clean in ${MAKE} buildkernel @@ -179,7 +178,7 @@ BMAKE= MAKEOBJDIRPREFIX=${WORLDTMP} \ DESTDIR= \ BOOTSTRAPPING=${OSRELDATE} \ -DWITHOUT_HTML -DWITHOUT_INFO -DNO_LINT -DWITHOUT_MAN \ - -DWITHOUT_NLS -DNO_PIC -DNO_PROFILE -DNO_SHARED \ + -DWITHOUT_NLS -DNO_PIC -DWITHOUT_PROFILE -DNO_SHARED \ -DNO_CPU_CFLAGS -DNO_WARNS # build-tools stage @@ -371,7 +370,7 @@ _libraries: @echo "--------------------------------------------------------------" ${_+_}cd ${.CURDIR}; \ ${WMAKE} -DNO_FSCHG -DWITHOUT_HTML -DWITHOUT_INFO -DNO_LINT \ - -DWITHOUT_MAN -DWITHOUT_NLS -DNO_PROFILE libraries + -DWITHOUT_MAN -DWITHOUT_NLS -DWITHOUT_PROFILE libraries _depend: @echo @echo "--------------------------------------------------------------" @@ -461,7 +460,7 @@ WMAKE_TGTS+= _cleanobj _obj _build-tools WMAKE_TGTS+= _cross-tools .endif WMAKE_TGTS+= _includes _libraries _depend everything -.if ${TARGET_ARCH} == "amd64" && !defined(NO_LIB32) +.if ${TARGET_ARCH} == "amd64" && ${MK_LIB32} != "no" WMAKE_TGTS+= build32 .endif @@ -562,7 +561,7 @@ reinstall: @echo ">>> Installing everything" @echo "--------------------------------------------------------------" ${_+_}cd ${.CURDIR}; ${MAKE} -f Makefile.inc1 install -.if ${TARGET_ARCH} == "amd64" && !defined(NO_LIB32) +.if ${TARGET_ARCH} == "amd64" && ${MK_LIB32} != "no" ${_+_}cd ${.CURDIR}; ${MAKE} -f Makefile.inc1 install32 .endif @@ -571,7 +570,7 @@ redistribute: @echo ">>> Distributing everything" @echo "--------------------------------------------------------------" ${_+_}cd ${.CURDIR}; ${MAKE} -f Makefile.inc1 distribute -.if ${TARGET_ARCH} == "amd64" && !defined(NO_LIB32) +.if ${TARGET_ARCH} == "amd64" && ${MK_LIB32} != "no" ${_+_}cd ${.CURDIR}; ${MAKE} -f Makefile.inc1 distribute32 DISTRIBUTION=lib32 .endif diff --git a/gnu/lib/libg2c/Makefile b/gnu/lib/libg2c/Makefile index 0a2ed81d67d9..cb053b2ab61e 100644 --- a/gnu/lib/libg2c/Makefile +++ b/gnu/lib/libg2c/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + SRCDIR= ${.CURDIR}/../../../contrib/libf2c .PATH: ${SRCDIR} ${SRCDIR}/libU77 ${SRCDIR}/libF77 ${SRCDIR}/libI77 @@ -105,7 +107,7 @@ ${E77OBJS:.o=.So}: f2cext.c ${.ALLSRC:M*.c} .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" ${E77OBJS:.o=.po}: f2cext.c ${CC} -p ${CFLAGS} -c -DL${.PREFIX} -o ${.TARGET} ${.ALLSRC:M*.c} .endif diff --git a/gnu/lib/libgcc/Makefile b/gnu/lib/libgcc/Makefile index 6eb28b8ec1c0..fef49b646724 100644 --- a/gnu/lib/libgcc/Makefile +++ b/gnu/lib/libgcc/Makefile @@ -1,5 +1,6 @@ # $FreeBSD$ +.include .include "${.CURDIR}/../../usr.bin/cc/Makefile.tgt" GCCDIR= ${.CURDIR}/../../../contrib/gcc @@ -197,7 +198,7 @@ ${OBJS_S}: libgcc2.c ${XCC} -c ${PICFLAG} ${CFLAGS} -DL${.PREFIX} -o ${.TARGET} ${.ALLSRC:M*.c} .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" ${OBJS_P}: libgcc2.c ${XCC} -c -p ${CFLAGS} -DL${.PREFIX} -o ${.TARGET} ${.ALLSRC:M*.c} .endif @@ -214,7 +215,7 @@ ${ASM_S}: ${_lib1asmsrc} -o ${.TARGET} ${.ALLSRC:N*.h} .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" ${ASM_P}: ${_lib1asmsrc} ${XCC} -x assembler-with-cpp -p -c ${CFLAGS} -DL${.PREFIX} \ -o ${.TARGET} ${.ALLSRC:N*.h} diff --git a/gnu/lib/libgcov/Makefile b/gnu/lib/libgcov/Makefile index bcf4d2d3e6e7..c6ab0d5dd8d8 100644 --- a/gnu/lib/libgcov/Makefile +++ b/gnu/lib/libgcov/Makefile @@ -1,12 +1,13 @@ # $FreeBSD$ +NO_PROFILE= +.include .include "${.CURDIR}/../../usr.bin/cc/Makefile.tgt" GCCDIR= ${.CURDIR}/../../../contrib/gcc .PATH: ${GCCDIR}/config/${GCC_CPU} ${GCCDIR} LIB= gcov -NO_PROFILE= CFLAGS+= -DIN_GCC -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED CFLAGS+= -D_PTHREADS -DGTHREAD_USE_WEAK @@ -37,7 +38,7 @@ ${OBJS_S}: libgcov.c ${CC} -c ${PICFLAG} ${CFLAGS} -DL${.PREFIX} -o ${.TARGET} ${.ALLSRC:M*.c} .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" ${OBJS_P}: libgcc2.c ${CC} -c -p ${CFLAGS} -DL${.PREFIX} -o ${.TARGET} ${.ALLSRC:M*.c} .endif diff --git a/lib/libc_r/Makefile b/lib/libc_r/Makefile index 496c7e62484f..d59f3cc4f3df 100644 --- a/lib/libc_r/Makefile +++ b/lib/libc_r/Makefile @@ -30,7 +30,7 @@ SYMLINKS+=lib${LIB}.a ${LIBDIR}/libpthread.a .if !defined(NO_PIC) SYMLINKS+=lib${LIB}.so ${SHLIBDIR}/libpthread.so .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" SYMLINKS+=lib${LIB}_p.a ${LIBDIR}/libpthread_p.a .endif .endif diff --git a/lib/libncurses/Makefile b/lib/libncurses/Makefile index 488a2fcf97e5..4fddbdc5c8d7 100644 --- a/lib/libncurses/Makefile +++ b/lib/libncurses/Makefile @@ -245,7 +245,7 @@ SYMLINKS+=libncurses.so ${LIBDIR}/libtermlib.so SYMLINKS+=libncurses.so ${LIBDIR}/libmytinfo.so SYMLINKS+=libncurses.so ${LIBDIR}/libtinfo.so .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" SYMLINKS+=libncurses_p.a ${LIBDIR}/libcurses_p.a SYMLINKS+=libncurses_p.a ${LIBDIR}/libtermcap_p.a SYMLINKS+=libncurses_p.a ${LIBDIR}/libtermlib_p.a diff --git a/lib/libpam/modules/Makefile.inc b/lib/libpam/modules/Makefile.inc index d4f2bb3e0545..bd766fb5e725 100644 --- a/lib/libpam/modules/Makefile.inc +++ b/lib/libpam/modules/Makefile.inc @@ -3,7 +3,7 @@ PAMDIR= ${.CURDIR}/../../../../contrib/openpam NO_INSTALLLIB= -NO_PROFILE= +MK_PROFILE= no CFLAGS+= -I${PAMDIR}/include -I${.CURDIR}/../../libpam WARNS?= 4 diff --git a/lib/libthr/Makefile b/lib/libthr/Makefile index 8a63533d2769..1097155d42e8 100644 --- a/lib/libthr/Makefile +++ b/lib/libthr/Makefile @@ -7,6 +7,9 @@ # To included legacy CSRG sccsid strings, add -DLIBC_SCCS and -DSYSLIBC_SCCS # (for system call stubs) to CFLAGS below. -DSYSLIBC_SCCS affects just the # system call stubs. + +.include + LIB=thr SHLIB_MAJOR= 2 CFLAGS+=-DPTHREAD_KERNEL @@ -40,7 +43,7 @@ SYMLINKS+=lib${LIB}.a ${LIBDIR}/libpthread.a .if !defined(NO_PIC) SYMLINKS+=lib${LIB}.so ${SHLIBDIR}/libpthread.so .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" SYMLINKS+=lib${LIB}_p.a ${LIBDIR}/libpthread_p.a .endif .endif diff --git a/lib/ncurses/ncurses/Makefile b/lib/ncurses/ncurses/Makefile index 488a2fcf97e5..4fddbdc5c8d7 100644 --- a/lib/ncurses/ncurses/Makefile +++ b/lib/ncurses/ncurses/Makefile @@ -245,7 +245,7 @@ SYMLINKS+=libncurses.so ${LIBDIR}/libtermlib.so SYMLINKS+=libncurses.so ${LIBDIR}/libmytinfo.so SYMLINKS+=libncurses.so ${LIBDIR}/libtinfo.so .endif -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" SYMLINKS+=libncurses_p.a ${LIBDIR}/libcurses_p.a SYMLINKS+=libncurses_p.a ${LIBDIR}/libtermcap_p.a SYMLINKS+=libncurses_p.a ${LIBDIR}/libtermlib_p.a diff --git a/release/Makefile b/release/Makefile index 7a7bc7bd4011..f7a19a778db1 100644 --- a/release/Makefile +++ b/release/Makefile @@ -375,8 +375,8 @@ release rerelease: .endif mkdir -p ${CHROOTDIR} @echo ">>> make release for ${TARGET} started on `LC_ALL=C TZ=GMT date`" - cd ${WORLDDIR} && ${NATIVEMAKE} -DWITHOUT_GAMES -DWITHOUT_HTML -DNO_LIB32 \ - -DWITHOUT_MAN -DWITHOUT_NLS -DNO_PROFILE installworld DESTDIR=${CHROOTDIR} + cd ${WORLDDIR} && ${NATIVEMAKE} -DWITHOUT_GAMES -DWITHOUT_HTML -DWITHOUT_LIB32 \ + -DWITHOUT_MAN -DWITHOUT_NLS -DWITHOUT_PROFILE installworld DESTDIR=${CHROOTDIR} cd ${WORLDDIR} && ${NATIVEMAKE} distribution DESTDIR=${CHROOTDIR} if [ -f /etc/resolv.conf ]; then \ cp -p /etc/resolv.conf ${CHROOTDIR}/etc; \ diff --git a/share/mk/bsd.lib.mk b/share/mk/bsd.lib.mk index b968ff822581..8dfd19561d05 100644 --- a/share/mk/bsd.lib.mk +++ b/share/mk/bsd.lib.mk @@ -155,7 +155,7 @@ lib${LIB}.a: ${OBJS} ${STATICOBJS} .if !defined(INTERNALLIB) -.if !defined(NO_PROFILE) && defined(LIB) && !empty(LIB) +.if ${MK_PROFILE} != "no" && defined(LIB) && !empty(LIB) _LIBS+= lib${LIB}_p.a POBJS+= ${OBJS:.o=.po} ${STATICOBJS:.o=.po} @@ -251,7 +251,7 @@ _libinstall: ${INSTALL} -C -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ ${_INSTALLFLAGS} lib${LIB}.a ${DESTDIR}${LIBDIR} .endif -.if !defined(NO_PROFILE) && defined(LIB) && !empty(LIB) +.if ${MK_PROFILE} != "no" && defined(LIB) && !empty(LIB) ${INSTALL} -C -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ ${_INSTALLFLAGS} lib${LIB}_p.a ${DESTDIR}${LIBDIR} .endif @@ -330,7 +330,7 @@ clean: rm -f a.out ${OBJS} ${OBJS:S/$/.tmp/} ${STATICOBJS} .endif .if !defined(INTERNALLIB) -.if !defined(NO_PROFILE) && defined(LIB) && !empty(LIB) +.if ${MK_PROFILE} != "no" && defined(LIB) && !empty(LIB) rm -f ${POBJS} ${POBJS:S/$/.tmp/} .endif .if defined(SHLIB_NAME) || \ diff --git a/usr.bin/lex/lib/Makefile b/usr.bin/lex/lib/Makefile index 51d71b6402d9..f94eaab03d02 100644 --- a/usr.bin/lex/lib/Makefile +++ b/usr.bin/lex/lib/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + LIB= ln SRCS= libmain.c libyywrap.c NO_PIC= @@ -7,7 +9,7 @@ NO_PIC= LINKS= ${LIBDIR}/libln.a ${LIBDIR}/libl.a LINKS+= ${LIBDIR}/libln.a ${LIBDIR}/libfl.a -.if !defined(NO_PROFILE) +.if ${MK_PROFILE} != "no" LINKS+= ${LIBDIR}/libln_p.a ${LIBDIR}/libl_p.a LINKS+= ${LIBDIR}/libln_p.a ${LIBDIR}/libfl_p.a .endif