Commit 2358deb6 authored by Simon J. Gerraty's avatar Simon J. Gerraty
Browse files

Import bmake-20180222

From ChangeLog

* VERSION: 20180222
  Merge with NetBSD make, pick up
  o parse.c: avoid calling sysconf for every call to loadfile

* VERSION: 20180218
  Merge with NetBSD make, pick up
  o var.c: Var_Set handle NULL value anytime.

* VERSION: 20180212
  Merge with NetBSD make, pick up
  o parse.c: do not treat .info as warning with -W

* VERSION: 20171207
  Merge with NetBSD make, pick up
  o var.c: Var_Append use Var_Set if var not previously set
    so that VAR_CMD is handled correctly.
    Add a suitable unit-test.

* VERSION: 20171126

* aclocal.m4: use AC_LINK_IFELSE for AC_C___ATTRIBUTE__
  since AC_TRY_COMPILE puts input inside main()
  which upsets modern compilers.

* VERSION: 20171118
  Merge with NetBSD make, pick up
  o var.c: do not append to variable set on command line
    add unit-test to catch this.
parent ade1697b
2018-02-22 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION: 20180222
Merge with NetBSD make, pick up
o parse.c: avoid calling sysconf for every call to loadfile
2018-02-18 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION: 20180218
Merge with NetBSD make, pick up
o var.c: Var_Set handle NULL value anytime.
2018-02-12 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION: 20180212
Merge with NetBSD make, pick up
o parse.c: do not treat .info as warning with -W
2017-12-07 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION: 20171207
Merge with NetBSD make, pick up
o var.c: Var_Append use Var_Set if var not previously set
so that VAR_CMD is handled correctly.
Add a suitable unit-test.
2017-11-26 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION (_MAKE_VERSION): 20171126
* aclocal.m4: use AC_LINK_IFELSE for AC_C___ATTRIBUTE__
since AC_TRY_COMPILE puts input inside main()
which upsets modern compilers.
2017-11-18 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION: 20171118
Merge with NetBSD make, pick up
o var.c: do not append to variable set on command line
add unit-test to catch this.
2017-10-28 Simon J. Gerraty <sjg@bad.crufty.net>
* VERSION: 20171028
......
......@@ -15,7 +15,7 @@ LDFLAGS= @LDFLAGS@
LIBOBJS= @LIBOBJS@
LDADD= @LIBS@
USE_META= @use_meta@
FILEMON_H= @filemon_h@
FILEMON_H?= @filemon_h@
BMAKE_PATH_MAX?= @bmake_path_max@
# used if MAXPATHLEN not defined
CPPFLAGS+= -DBMAKE_PATH_MAX=${BMAKE_PATH_MAX}
# keep this compatible with sh and make
_MAKE_VERSION=20171028
_MAKE_VERSION=20180222
dnl RCSid:
dnl $Id: aclocal.m4,v 1.5 2003/03/06 21:21:30 sjg Exp $
dnl $Id: aclocal.m4,v 1.6 2017/11/26 22:39:20 sjg Exp $
dnl
dnl
......@@ -55,10 +55,9 @@ dnl
AC_DEFUN(AC_C___ATTRIBUTE__, [
AC_MSG_CHECKING(for __attribute__)
AC_CACHE_VAL(ac_cv___attribute__, [
AC_TRY_COMPILE([
AC_LINK_IFELSE([
#include <stdlib.h>
],
[
static void foo(void) __attribute__ ((noreturn));
static void
......@@ -66,6 +65,12 @@ foo(void)
{
exit(1);
}
int
main(int argc, char **argv)
{
foo();
}
],
ac_cv___attribute__=yes,
ac_cv___attribute__=no)])
......
This diff is collapsed.
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.64 for bmake 20170812.
# Generated by GNU Autoconf 2.64 for bmake 20171126.
#
# Report bugs to <sjg@NetBSD.org>.
#
......@@ -549,8 +549,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='bmake'
PACKAGE_TARNAME='bmake'
PACKAGE_VERSION='20170812'
PACKAGE_STRING='bmake 20170812'
PACKAGE_VERSION='20171126'
PACKAGE_STRING='bmake 20171126'
PACKAGE_BUGREPORT='sjg@NetBSD.org'
PACKAGE_URL=''
......@@ -1222,7 +1222,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures bmake 20170812 to adapt to many kinds of systems.
\`configure' configures bmake 20171126 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
......@@ -1283,7 +1283,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of bmake 20170812:";;
short | recursive ) echo "Configuration of bmake 20171126:";;
esac
cat <<\_ACEOF
......@@ -1388,7 +1388,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
bmake configure 20170812
bmake configure 20171126
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
......@@ -1961,7 +1961,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by bmake $as_me 20170812, which was
It was created by bmake $as_me 20171126, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
......@@ -4722,10 +4722,6 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
#include <stdlib.h>
int
main ()
{
static void foo(void) __attribute__ ((noreturn));
static void
......@@ -4734,16 +4730,20 @@ foo(void)
exit(1);
}
;
return 0;
int
main(int argc, char **argv)
{
foo();
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
if ac_fn_c_try_link "$LINENO"; then :
ac_cv___attribute__=yes
else
ac_cv___attribute__=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
fi
if test "$ac_cv___attribute__" = "yes"; then
......@@ -6517,7 +6517,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by bmake $as_me 20170812, which was
This file was extended by bmake $as_me 20171126, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
......@@ -6577,7 +6577,7 @@ Report bugs to <sjg@NetBSD.org>."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
bmake config.status 20170812
bmake config.status 20171126
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
......
dnl
dnl RCSid:
dnl $Id: configure.in,v 1.58 2017/08/13 00:56:10 sjg Exp $
dnl $Id: configure.in,v 1.59 2017/11/26 22:39:20 sjg Exp $
dnl
dnl Process this file with autoconf to produce a configure script
dnl
AC_PREREQ(2.50)
AC_INIT([bmake], [20170812], [sjg@NetBSD.org])
AC_INIT([bmake], [20171126], [sjg@NetBSD.org])
AC_CONFIG_HEADERS(config.h)
dnl make srcdir absolute
......
/* $NetBSD: job.c,v 1.191 2017/07/20 19:29:54 sjg Exp $ */
/* $NetBSD: job.c,v 1.192 2018/02/08 09:05:21 dholland Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
......@@ -70,14 +70,14 @@
*/
#ifndef MAKE_NATIVE
static char rcsid[] = "$NetBSD: job.c,v 1.191 2017/07/20 19:29:54 sjg Exp $";
static char rcsid[] = "$NetBSD: job.c,v 1.192 2018/02/08 09:05:21 dholland Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)job.c 8.2 (Berkeley) 3/19/94";
#else
__RCSID("$NetBSD: job.c,v 1.191 2017/07/20 19:29:54 sjg Exp $");
__RCSID("$NetBSD: job.c,v 1.192 2018/02/08 09:05:21 dholland Exp $");
#endif
#endif /* not lint */
#endif
......@@ -102,7 +102,7 @@ __RCSID("$NetBSD: job.c,v 1.191 2017/07/20 19:29:54 sjg Exp $");
* a time given by the SEL_* constants, below,
* or until output is ready.
*
* Job_Init Called to intialize this module. in addition,
* Job_Init Called to initialize this module. in addition,
* any commands attached to the .BEGIN target
* are executed before this function returns.
* Hence, the makefile must have been parsed
......
/* $NetBSD: make.h,v 1.103 2017/07/20 19:29:54 sjg Exp $ */
/* $NetBSD: make.h,v 1.104 2018/02/12 21:38:09 sjg Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
......@@ -346,6 +346,7 @@ typedef struct GNode {
* once the makefile has been parsed. PARSE_WARNING means it can. Passed
* as the first argument to Parse_Error.
*/
#define PARSE_INFO 3
#define PARSE_WARNING 2
#define PARSE_FATAL 1
......
/* $NetBSD: meta.c,v 1.69 2017/08/10 21:07:48 sjg Exp $ */
/* $NetBSD: meta.c,v 1.70 2018/02/13 19:37:30 sjg Exp $ */
/*
* Implement 'meta' mode.
......@@ -790,7 +790,9 @@ meta_cmd_finish(void *pbmp)
{
int error = 0;
BuildMon *pbm = pbmp;
#ifdef USE_FILEMON
int x;
#endif
if (!pbm)
pbm = &Mybm;
......
2018-01-18 Simon J Gerraty <sjg@beast.crufty.net>
* install-mk (MK_VERSION): 20180118
* ldorder.mk: let make compute correct link order
2017-12-12 Simon J Gerraty <sjg@beast.crufty.net>
* install-mk (MK_VERSION): 20171212
* gendirdeps.mk: guard against bogus entries in GENDIRDEPS_FILTER
2017-11-14 Simon J. Gerraty <sjg@bad.crufty.net>
* install-mk (MK_VERSION): 20171111
* lib.mk: ensure META_NOECHO is set
2017-10-25 Simon J. Gerraty <sjg@bad.crufty.net>
* Allow for host32 on rare occasions.
......
......@@ -17,6 +17,7 @@ inc.mk
init.mk
install-mk
java.mk
ldorder.mk
lib.mk
libnames.mk
libs.mk
......
# $Id: auto.obj.mk,v 1.14 2017/04/18 23:53:18 sjg Exp $
# $Id: auto.obj.mk,v 1.15 2017/11/04 21:05:04 sjg Exp $
#
# @(#) Copyright (c) 2004, Simon J. Gerraty
#
......@@ -60,11 +60,17 @@ __objdir_made != echo ${__objdir}/; umask ${OBJDIR_UMASK:U002}; \
.endif
# This causes make to use the specified directory as .OBJDIR
.OBJDIR: ${__objdir}
.if ${.OBJDIR:tA} != ${__objdir:tA} && ${__objdir_made:Uno:M${__objdir}/*} != ""
.if ${.OBJDIR:tA} != ${__objdir:tA}
# we did not get what we want - do we care?
.if ${__objdir_made:Uno:M${__objdir}/*} != ""
# watch out for __objdir being relative path
.if !(${__objdir:M/*} == "" && ${.OBJDIR:tA} == ${${.CURDIR}/${__objdir}:L:tA})
.error could not use ${__objdir}: .OBJDIR=${.OBJDIR}
.endif
.endif
# apparently we can live with it
# make sure we know what we have
.OBJDIR: ${.CURDIR}
.endif
.endif
.endif
# $Id: dpadd.mk,v 1.24 2017/10/25 23:44:20 sjg Exp $
# $Id: dpadd.mk,v 1.26 2018/02/12 21:54:26 sjg Exp $
#
# @(#) Copyright (c) 2004, Simon J. Gerraty
#
......@@ -60,6 +60,7 @@ LDADD += ${LDADD_${__lib:T:R}:U${__lib:T:R:S/lib/-l/:C/\.so.*//}}
# DPADD can contain things other than libs
__dpadd_libs := ${DPADD:M*/lib*}
.if defined(PROG) && ${MK_PROG_LDORDER_MK:Uno} != "no"
# some libs have dependencies...
# DPLIBS_* allows bsd.libnames.mk to flag libs which must be included
# in DPADD for a given library.
......@@ -73,6 +74,7 @@ __ldadd_all_xtras+= ${LDADD_${__lib}:U${__lib:T:R:S/lib/-l/:C/\.so.*//}}
DPADD+= ${__lib}
.endif
.endfor
.endif
# Last of all... for libc and libgcc
DPADD+= ${DPADD_LAST}
......@@ -125,9 +127,11 @@ SRC_LIBS+= ${_OBJDIR}/lib${LIB}.a
#
SRC_LIBS?=
__dpadd_libs += ${SRC_LIBS}
DPMAGIC_LIBS += ${__dpadd_libs} \
${__dpadd_libs:@d@${DPMAGIC_LIBS_${d:T:R}}@}
# magic_libs includes those we want to link with
# as well as those we might look at
__dpadd_magic_libs += ${__dpadd_libs} ${SRC_LIBS}
DPMAGIC_LIBS += ${__dpadd_magic_libs} \
${__dpadd_magic_libs:@d@${DPMAGIC_LIBS_${d:T:R}}@}
# we skip this for staged libs
.for __lib in ${DPMAGIC_LIBS:O:u:N${STAGE_OBJTOP:Unot}*/lib/*}
......@@ -189,11 +193,11 @@ LDADD := ${LDADD:S,^${__ldadd}$,${__ldadd}_p,g}
#
# We take care of duplicate suppression later.
# don't apply :T:R too early
__dpadd_incs += ${__dpadd_libs:u:@x@${INCLUDES_${x:T:R}}@}
__dpadd_incs += ${__dpadd_libs:O:u:@s@${SRC_LIBS_${s:T:R}:U}@:@x@${INCLUDES_${x:T:R}}@}
__dpadd_incs += ${__dpadd_magic_libs:u:@x@${INCLUDES_${x:T:R}}@}
__dpadd_incs += ${__dpadd_magic_libs:O:u:@s@${SRC_LIBS_${s:T:R}:U}@:@x@${INCLUDES_${x:T:R}}@}
__dpadd_last_incs += ${__dpadd_libs:u:@x@${INCLUDES_LAST_${x:T:R}}@}
__dpadd_last_incs += ${__dpadd_libs:O:u:@s@${SRC_LIBS_${s:T:R}:U}@:@x@${INCLUDES_LAST_${x:T:R}}@}
__dpadd_last_incs += ${__dpadd_magic_libs:u:@x@${INCLUDES_LAST_${x:T:R}}@}
__dpadd_last_incs += ${__dpadd_magic_libs:O:u:@s@${SRC_LIBS_${s:T:R}:U}@:@x@${INCLUDES_LAST_${x:T:R}}@}
.if defined(HOSTPROG) || ${MACHINE:Nhost*} == ""
# we want any -I/usr/* last
......
# $Id: final.mk,v 1.8 2017/05/07 20:30:08 sjg Exp $
# $Id: final.mk,v 1.9 2018/01/24 22:57:11 sjg Exp $
.if !target(__${.PARSEFILE}__)
__${.PARSEFILE}__:
......@@ -6,14 +6,14 @@ __${.PARSEFILE}__:
# provide a hook for folk who want to do scary stuff
.-include <${.CURDIR:H}/Makefile-final.inc>
.-include <local.final.mk>
.if ${MK_STAGING} == "yes"
.include <meta.stage.mk>
.elif !empty(STAGE)
.-include <stage.mk>
.endif
.-include <local.final.mk>
.if empty(_SKIP_BUILD)
install: realinstall
.endif
......
# $Id: gendirdeps.mk,v 1.34 2017/10/26 00:46:26 sjg Exp $
# $Id: gendirdeps.mk,v 1.37 2018/01/31 19:06:46 sjg Exp $
# Copyright (c) 2010-2013, Juniper Networks, Inc.
# All rights reserved.
......@@ -255,7 +255,9 @@ DIRDEPS += \
${dirdep_list:M${RELDIR}/*:@d@${.MAKE.MAKEFILE_PREFERENCE:@m@${exists(${SRCTOP}/$d/$m):?$d:${exists(${SRCTOP}/${d:R}/$m):?$d:}}@}@} \
${qualdir_list:M${RELDIR}/*:@d@${.MAKE.MAKEFILE_PREFERENCE:@m@${exists(${SRCTOP}/${d:R}/$m):?$d:}@}@}
DIRDEPS := ${DIRDEPS:${GENDIRDEPS_FILTER:UNno:ts:}:C,//+,/,g:O:u}
# what modifiers do we allow in GENDIRDEPS_FILTER
GENDIRDEPS_FILTER_MASK += @CMNS
DIRDEPS := ${DIRDEPS:${GENDIRDEPS_FILTER:UNno:M[${GENDIRDEPS_FILTER_MASK:O:u:ts}]*:ts:}:C,//+,/,g:O:u}
.if ${DEBUG_GENDIRDEPS:Uno:@x@${RELDIR:M$x}@} != ""
.info ${RELDIR}: M2D_OBJROOTS=${M2D_OBJROOTS}
......
......@@ -55,7 +55,7 @@
# Simon J. Gerraty <sjg@crufty.net>
# RCSid:
# $Id: install-mk,v 1.150 2017/10/19 03:50:51 sjg Exp $
# $Id: install-mk,v 1.153 2018/01/24 22:57:11 sjg Exp $
#
# @(#) Copyright (c) 1994 Simon J. Gerraty
#
......@@ -70,7 +70,7 @@
# sjg@crufty.net
#
MK_VERSION=20171018
MK_VERSION=20180118
OWNER=
GROUP=
MODE=444
......
# $Id: ldorder.mk,v 1.18 2018/02/11 18:27:59 sjg Exp $
#
# @(#) Copyright (c) 2015, Simon J. Gerraty
#
# This file is provided in the hope that it will
# be of use. There is absolutely NO WARRANTY.
# Permission to copy, redistribute or otherwise
# use this file is hereby granted provided that
# the above copyright notice and this notice are
# left intact.
#
# Please send copies of changes and bug-fixes to:
# sjg@crufty.net
#
# Try to compute optimal link order.
# When using only shared libs link order does not much matter,
# but archive libs are a different matter.
# We can construct a graph of .ldorder-lib${LIB*} dependencies
# and associate each with _LDORDER_USE to output the relevant
# ld flags.
# Due to the nature of make, the result will be in the reverse order
# that we want to feed to ld.
# So we need to reverse it before use.
.if !target(_LDORDER_USE)
# does caller want to use ldorder?
# yes for prog, normally no for lib
_ldorder_use := ${.ALLTARGETS:Mldorder}
.-include <local.ldorder.mk>
# convert /path/to/libfoo.a into _{LIBFOO}
LDORDER_INC_FILTER += S,+,PLUS,g S,.so$$,,g
LDORDER_LIBS_FILTER += O:u
LDORDER_INC ?= ldorder.inc
REFERENCE_FILE ?= :
_LDORDER_USE: .ldorder-rm .USE .NOTMAIN
@echo depends: ${.ALLSRC:M.ldorder-lib*} > /dev/null
@echo ${LDADD_${.TARGET:T:S,.ldorder-,,}:U${.TARGET:T:S/.ldorder-lib/-l/}} >> .ldorder
@${META_COOKIE_TOUCH}
# we need to truncate our working file
.ldorder-rm: .NOTMAIN
@rm -f .ldorder ldorder-*
@${.ALLSRC:O:u:@f@${REFERENCE_FILE} < $f;@}
@${META_COOKIE_TOUCH}
# make sure this exists
.ldorder: .NOTMAIN
# and finally we need to reverse the order of content
ldorder: .ldorder .NOTMAIN
@{ test ! -s .ldorder || cat -n .ldorder | sort -rn | \
sed '/ldorder-/d;s,^[[:space:]0-9]*,,'; } > ${.TARGET}
# Initially we hook contents of DPLIBS and DPADD into our graph
LDORDER_LIBS ?= ${DPLIBS} ${DPADD:M*/lib*} ${__dpadd_libs}
# we need to remember this
_LDORDER_LIBS := ${LDORDER_LIBS:${LDORDER_LIBS_FILTER:ts:}}
.if empty(_LDORDER_LIBS)
# don't use stale ldorder
LDADD_LDORDER =
.else
# this is how you use it
LDADD_LDORDER ?= `cat ldorder`
.endif
# for debug below
_ldorder = ${RELDIR}.${TARGET_SPEC}
.endif # !target(_LDORDER_USE)
.if !empty(LDORDER_LIBS) && !empty(_ldorder_use)
# canonicalize - these are just tokens anyway
LDORDER_LIBS := ${LDORDER_LIBS:${LDORDER_LIBS_FILTER:ts:}:R:C/\.so.*//}
_ldorders := ${LDORDER_LIBS:T:Mlib*:S,^,.ldorder-,}
.for t in ${_ldorders}
.if !target($t)
$t: _LDORDER_USE
.endif
.endfor
# and this makes it all happen
.ldorder: ${_ldorders}
# this is how we get the dependencies
.if ${.INCLUDEDFROMFILE:M*.${LDORDER_INC}} != ""
_ldorder := .ldorder-${.INCLUDEDFROMFILE:S/.${LDORDER_INC}//}
${_ldorder}: ${_ldorders}
.ldorder-rm: ${.INCLUDEDFROMDIR}/${.INCLUDEDFROMFILE}
.endif
# set DEBUG_LDORDER to pattern[s] that match the dirs of interest
.if ${DEBUG_LDORDER:Uno:@x@${RELDIR:M$x}@} != ""
.info ${_ldorder}: ${_ldorders}
.endif
# now try to find more ...
# each *.${LDORDER_INC} should set LDORDER_LIBS to what it needs
# it can also add to CFLAGS etc.
.for __inc in ${LDORDER_LIBS:S,$,.${LDORDER_INC},}
.if !target(__${__inc}__)
__${__inc}__:
# make sure this is reset
LDORDER_LIBS =
.-include <${__inc}>
.endif
.endfor
.endif # !empty(LDORDER_LIBS)
.ifdef LIB
# you can make this depend on files (must match *ldorder*)
# to add extra content - like CFLAGS
libLDORDER_INC = lib${LIB}.${LDORDER_INC}
.if !commands(${libLDORDER_INC})
${libLDORDER_INC}:
@(cat /dev/null ${.ALLSRC:M*ldorder*}; \
echo 'LDORDER_LIBS= ${_LDORDER_LIBS:T:R:${LDORDER_INC_FILTER:ts:}:tu:C,.*,_{&},}'; \
echo; echo '.include <ldorder.mk>' ) | sed 's,_{,$${,g' > ${.TARGET}
.endif
.endif
# $Id: lib.mk,v 1.62 2017/06/11 03:24:04 sjg Exp $
# $Id: lib.mk,v 1.68 2018/01/26 20:08:16 sjg Exp $
.if !target(__${.PARSEFILE}__)
__${.PARSEFILE}__:
......@@ -37,6 +37,8 @@ PICO?= .pico
CFLAGS+= ${COPTS}
META_NOECHO?= echo
# Originally derrived from NetBSD-1.6
# Set PICFLAGS to cc flags for producing position-independent code,
......@@ -370,6 +372,11 @@ _LIBS+=llib-l${LIB}.ln
.if empty(LIB)
_LIBS=
.elif ${MK_LDORDER_MK} != "no"
# Record any libs that we need to be linked with
_LIBS+= ${libLDORDER_INC}
.include <ldorder.mk>
.endif
.if !defined(_SKIP_BUILD)
......@@ -507,20 +514,24 @@ libinstall:
[ -d ${DESTDIR}/${LIBDIR} ] || \
${INSTALL} -d ${LIB_INSTALL_OWN} -m 775 ${DESTDIR}${LIBDIR}
.if ${MK_ARCHIVE} != "no"
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 600 lib${LIB}.a \
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 644 lib${LIB}.a \
${DESTDIR}${LIBDIR}
${RANLIB} ${DESTDIR}${LIBDIR}/lib${LIB}.a
chmod ${LIBMODE} ${DESTDIR}${LIBDIR}/lib${LIB}.a
.endif
.if ${MK_PROFILE} != "no"
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 600 \
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 644 \
lib${LIB}_p.a ${DESTDIR}${LIBDIR}
${RANLIB} ${DESTDIR}${LIBDIR}/lib${LIB}_p.a
chmod ${LIBMODE} ${DESTDIR}${LIBDIR}/lib${LIB}_p.a
.endif
.if ${MK_LDORDER_MK} != "no"
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 644 \
lib${LIB}.ldorder.inc ${DESTDIR}${LIBDIR}
.endif
.if ${MK_PIC} != "no"
.if ${MK_PICLIB} != "no"
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 600 \
${INSTALL} ${COPY} ${LIB_INSTALL_OWN} -m 644 \
lib${LIB}_pic.a ${DESTDIR}${LIBDIR}
${RANLIB} ${DESTDIR}${LIBDIR}/lib${LIB}_pic.a
chmod ${LIBMODE} ${DESTDIR}${LIBDIR}/lib${LIB}_pic.a
......
# $Id: own.mk,v 1.36 2017/07/08 21:58:46 sjg Exp $
# $Id: own.mk,v 1.39 2018/01/26 20:08:16 sjg Exp $
.if !target(__${.PARSEFILE}__)
__${.PARSEFILE}__:
......@@ -91,6 +91,7 @@ OPTIONS_DEFAULT_NO+= DPADD_MK
OPTIONS_DEFAULT_NO+= \
INSTALL_AS_USER \
GPROF \
LDORDER_MK \
LIBTOOL \
LINT \
......@@ -113,6 +114,7 @@ OPTIONS_DEFAULT_YES+= \
OPTIONS_DEFAULT_DEPENDENT+= \
CATPAGES/MAN \
PROG_LDORDER_MK/LDORDER_MK \
OBJDIRS/OBJ \
PICINSTALL/LINKLIB \
PICLIB/PIC \
......