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# Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved. 23# 24# Copyright 2010, Richard Lowe 25# 26# Copyright 2020 Joyent, Inc. 27# Copyright 2020 OmniOS Community Edition (OmniOSce) Association. 28# Copyright 2022 Jason King 29 30SHELL=/usr/bin/ksh93 31 32SCRIPTS= \ 33 bldenv \ 34 nightly 35 36SHFILES= \ 37 Install \ 38 build_cscope \ 39 checkpaths \ 40 cstyle \ 41 elfcmp \ 42 flg.flp \ 43 genoffsets \ 44 onu \ 45 protocmp.terse \ 46 webrev \ 47 which_scm \ 48 ws \ 49 xref 50 51PERLFILES= \ 52 check_rtime \ 53 interface_check \ 54 interface_cmp \ 55 jstyle \ 56 validate_flg \ 57 validate_paths \ 58 wdiff 59 60PERLMODULES= \ 61 onbld_elfmod.pm \ 62 onbld_elfmod_vertype.pm 63 64 65PYFILES= \ 66 cddlchk \ 67 copyrightchk \ 68 git-pbchk \ 69 hdrchk \ 70 mapfilechk \ 71 validate_pkg \ 72 wscheck \ 73 wsdiff 74 75SCRIPTLINKS= \ 76 git-nits 77 78MAN1ONBLDFILES= \ 79 Install.1onbld \ 80 bldenv.1onbld \ 81 cddlchk.1onbld \ 82 checkpaths.1onbld \ 83 check_rtime.1onbld \ 84 ctfconvert.1onbld \ 85 cstyle.1onbld \ 86 flg.flp.1onbld \ 87 git-pbchk.1onbld \ 88 hdrchk.1onbld \ 89 interface_check.1onbld \ 90 interface_cmp.1onbld \ 91 jstyle.1onbld \ 92 mapfilechk.1onbld \ 93 nightly.1onbld \ 94 onu.1onbld \ 95 webrev.1onbld \ 96 which_scm.1onbld \ 97 ws.1onbld \ 98 wsdiff.1onbld \ 99 xref.1onbld 100 101MAN1ONBLDLINKS= \ 102 git-nits.1onbld 103 104MAKEFILES= \ 105 xref.mk 106 107ETCFILES= \ 108 its.conf \ 109 its.reg 110 111EXCEPTFILES= \ 112 check_rtime \ 113 interface_check \ 114 interface_cmp 115 116CLEANFILES = $(SHFILES) $(PERLFILES) $(PYFILES) bldenv.1onbld onu.sh 117 118include ../Makefile.tools 119 120ROOTONBLDSCRIPTLINKS = $(SCRIPTLINKS:%=$(ROOTONBLDBIN)/%) 121ROOTONBLDMAN1ONBLDLINKS = $(MAN1ONBLDLINKS:%=$(ROOTONBLDMAN1ONBLD)/%) 122 123$(ROOTONBLDETCFILES) := FILEMODE= 644 124$(ROOTONBLDEXCEPTFILES) := FILEMODE= 644 125$(ROOTONBLDPERLMODULES) := FILEMODE= 644 126$(ROOTONBLDMAKEFILES) := FILEMODE= 644 127$(ROOTONBLDMAN1ONBLDFILES) := FILEMODE= 644 128 129.KEEP_STATE: 130 131all: $(SHFILES) $(PERLFILES) $(PERLMODULES) $(PYFILES) \ 132 $(MAN1ONBLDFILES) $(MAKEFILES) $(SCRIPTS) 133 134onu.sh: onu.sh.in 135 $(SED) -e "s:@PYTHON_VERSION@:$(PYTHON3_VERSION):g" < onu.sh.in > $@ 136 137$(ROOTONBLDBIN)/git-nits: 138 $(RM) $(ROOTONBLDBIN)/git-nits 139 $(SYMLINK) git-pbchk $(ROOTONBLDBIN)/git-nits 140 141$(ROOTONBLDMAN1ONBLD)/git-nits.1onbld: 142 $(RM) $(ROOTONBLDMAN1ONBLD)/git-nits.1onbld 143 $(SYMLINK) git-pbchk.1onbld $(ROOTONBLDMAN1ONBLD)/git-nits.1onbld 144 145install: all .WAIT $(ROOTONBLDSHFILES) $(ROOTONBLDPERLFILES) \ 146 $(ROOTONBLDPERLMODULES) $(ROOTONBLDPYFILES) \ 147 $(ROOTONBLDSCRIPTLINKS) $(ROOTONBLDMAN1ONBLDFILES) \ 148 $(ROOTONBLDMAKEFILES) $(ROOTONBLDETCFILES) \ 149 $(ROOTONBLDEXCEPTFILES) $(ROOTONBLDMAN1ONBLDLINKS) \ 150 $(ROOTONBLDSCRIPTS) 151 152clean: 153 $(RM) $(CLEANFILES) 154 155bldenv.1onbld: bldenv 156 $(RM) "$@" 157 (set +o errexit ; ksh93 $? --nroff ; true) 2>&1 | \ 158 sed -e 's/\.DS/.nf/g;s/\.DE/.fi/' \ 159 -e 's/\.TH BLDENV 1/.TH BLDENV 1ONBLD "September 4, 2018"/' \ 160 -e 's/.OP \([a-z]\) - flag -/.OP \\-\1/g' \ 161 -e 's/(1)/(1ONBLD)/' > "$@" 162 163# 164# Not run by default: bootstrap... 165check: 166 $(ROOTONBLDBINMACH)/mandoc -Tlint -Wwarning $(MAN1ONBLDFILES) 167 168include ../Makefile.targ 169 170