VirtualBox

Changeset 3138 in kBuild for vendor/gnumake/current/maintMakefile


Ignore:
Timestamp:
Mar 12, 2018 7:32:29 PM (7 years ago)
Author:
bird
Message:

Imported make 4.2.1 (2e55f5e4abdc0e38c1d64be703b446695e70b3b6) from https://git.savannah.gnu.org/git/make.git.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vendor/gnumake/current/maintMakefile

    r2596 r3138  
    11# Maintainer-only makefile segment.  This contains things that are relevant
    2 # only if you have the full copy of the GNU make sources from the CVS
     2# only if you have the full copy of the GNU make sources from the Git
    33# tree, not a dist copy.
    44
     5BUGLIST := bug-make@gnu.org
     6
     7# These are related to my personal setup.
     8GPG_FINGERPRINT := 6338B6D4
     9
     10# SRCROOTDIR is just a handy location to keep source files in
     11SRCROOTDIR ?= $(HOME)/src
     12
     13# Where the gnulib project has been locally cloned
     14GNULIBDIR ?= $(SRCROOTDIR)/gnulib
     15
     16# Where to put the CVS checkout of the GNU web repository
     17GNUWEBDIR ?= $(SRCROOTDIR)/gnu-www
     18
     19# Where to put the CVS checkout of the GNU make web repository
     20MAKEWEBDIR ?= $(SRCROOTDIR)/make/make-web
     21
    522# We like mondo-warnings!
    6 AM_CFLAGS += -Wall -Wextra -Wdeclaration-after-statement -Wshadow -Wpointer-arith -Wbad-function-cast
     23AM_CFLAGS += -Wall -Wwrite-strings -Wextra -Wdeclaration-after-statement -Wshadow -Wpointer-arith -Wbad-function-cast
     24
     25MAKE_MAINTAINER_MODE := -DMAKE_MAINTAINER_MODE
     26AM_CPPFLAGS += $(MAKE_MAINTAINER_MODE)
    727
    828# I want this one but I have to wait for the const cleanup!
     
    1939# These are built as a side-effect of the dist rule
    2040#all-am: $(TEMPLATES) $(MTEMPLATES) build.sh.in
     41
     42# Create preprocessor output files--GCC specific!
     43%.i : %.c
     44        $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) -E -dD -o $@ $<
    2145
    2246# General rule for turning a .template into a regular file.
     
    81105         done) > $@
    82106
    83 # Get rid of everything "else".
    84 #
    85 maintFILES = configure aclocal.m4 config.h.in Makefile.in stamp-h.in
    86 
    87 CVS-CLEAN-FILES +=      $(maintFILES) $(TEMPLATES) $(MTEMPLATES) NMakefile \
    88                         build.sh.in .deps .dep_segment ABOUT-NLS \
    89                         ansi2knr.*
    90 
    91 # This rule tries to clean the tree right down to how it looks when you do a
    92 # virgin CVS checkout.
    93 
    94 # This target is potentially dangerous since it removes _ANY FILE_ that
    95 # is not in CVS.  Including files you might mean to add to CVS but
    96 # haven't yet...  I only use this in subdirectories where it's unlikely
    97 # we have any new files.  Still... be careful!!
    98 
    99 cvsclean = $(PERL) -e '$$k{CVS} = 1; open(E,"< CVS/Entries") || die "CVS/Entries: $$!\n"; while (defined ($$_ = <E>)) { m%^/([^/]*)% or next; $$k{$$1} = 1; } close(E) || die "CVS/Entries: $$!\n"; opendir(D, ".") || die ".: $$!\n"; while (defined ($$_ = readdir(D))) { -f $$_ && ! exists $$k{$$_} && unlink($$_); } closedir(D) || die ".: $$!\n";'
    100 
    101 .PHONY: cvs-clean
    102 cvs-clean: maintainer-clean
    103         -rm -rf *~ $(CVS-CLEAN-FILES)
    104         -cd config && $(cvsclean)
    105         -cd po     && $(cvsclean)
    106         -cd doc    && $(cvsclean)
    107         -cd glob   && $(cvsclean)
    108 
    109 
    110 # ----------------------------------------------------------------------
    111 #
    112 # The sections below were stolen from the Makefile.maint used by fileutils,
    113 # sh-utils, textutils, CPPI, Bison, and Autoconf.
     107# Cleaning
     108
     109GIT :=  git
     110
     111# git-clean:      Clean all "ignored" files.  Leave untracked files.
     112# git-very-clean: Clean all files that aren't stored in source control.
     113
     114.PHONY: git-clean git-very-clean
     115git-clean:
     116        -$(GIT) clean -fdX
     117git-very-clean: git-clean
     118        -$(GIT) clean -fd
     119
     120
     121
     122## ---------------------- ##
     123## Generating ChangeLog.  ##
     124## ---------------------- ##
     125
     126gl2cl-date := 2013-10-10
     127gl2cl := $(GNULIBDIR)/build-aux/gitlog-to-changelog
     128
     129# Rebuild the changelog whenever a new commit is added
     130ChangeLog: .check-git-HEAD
     131        if test -f '$(gl2cl)'; then \
     132            '$(gl2cl)' --since='$(gl2cl-date)' > '$@'; \
     133        else \
     134            echo "WARNING: $(gl2cl) is not available.  No $@ generated."; \
     135        fi
     136
     137.PHONY: .check-git-HEAD
     138.check-git-HEAD:
     139        sha="`git rev-parse HEAD`"; \
     140        [ -f '$@' ] && [ "`cat '$@' 2>/dev/null`" = "$$sha" ] \
     141            || echo "$$sha" > '$@'
    114142
    115143
     
    117145## Updating files.  ##
    118146## ---------------- ##
    119 
    120 WGET = wget --passive-ftp -nv
     147RSYNC = rsync -Lrtvz
     148WGET = wget --passive-ftp -np -nv
    121149ftp-gnu = ftp://ftp.gnu.org/gnu
    122150
     
    124152                    echo $(target) is unchanged; rm -f $(target).t; \
    125153                  else \
    126                     mv $(target).t $(target); \
     154                    mv -f $(target).t $(target); \
    127155                  fi
    128156
     
    136164#   ftp://tiger.informatik.hu-berlin.de/pub/po/maint/
    137165
     166po_wget_flags = --recursive --level=1 --no-directories --no-check-certificate
    138167po_repo = http://translationproject.org/latest/$(PACKAGE)
     168po_sync = translationproject.org::tp/latest/$(PACKAGE)/
     169
    139170.PHONY: do-po-update po-update
    140171do-po-update:
     
    142173          && rm -rf "$$tmppo" \
    143174          && mkdir "$$tmppo" \
    144           && (cd "$$tmppo" \
    145                 && $(WGET) -r -l1 -nd --no-parent -A '*.po' $(po_repo)) \
    146           && cp "$$tmppo"/*.po $(top_srcdir)/po && rm -rf "$$tmppo"
     175          && $(RSYNC) $(po_sync) "$$tmppo" \
     176          && cp "$$tmppo"/*.po $(top_srcdir)/po \
     177          && rm -rf "$$tmppo"
    147178        cd po && $(MAKE) update-po
    148179        $(MAKE) po-check
     
    193224
    194225
     226# ---------------------------------- #
     227# Alternative configuration checks.  #
     228# ---------------------------------- #
     229
     230.PHONY: check-alt-config
     231check-alt-config: \
     232        checkcfg.--disable-job-server \
     233        checkcfg.--disable-load \
     234        checkcfg.--without-guile \
     235        checkcfg.CPPFLAGS^-DNO_OUTPUT_SYNC \
     236        checkcfg.CPPFLAGS^-DNO_ARCHIVES
     237
     238# Trick GNU make so it doesn't run the submake as a recursive make.
     239NR_MAKE = $(MAKE)
     240
     241# Check builds both with build.sh and with make
     242checkcfg.%: distdir
     243        @echo "Building $@ (output in checkcfg.$*.log)"
     244        @exec >'checkcfg.$*.log' 2>&1; \
     245           rm -rf $(distdir)/_build \
     246        && mkdir $(distdir)/_build \
     247        && cd $(distdir)/_build \
     248        && echo "Testing configure with $(subst ^,=,$*)" \
     249        && ../configure --srcdir=.. $(subst ^,=,$*) \
     250                $(AM_DISTCHECK_CONFIGURE_FLAGS) $(DISTCHECK_CONFIGURE_FLAGS) \
     251                CFLAGS='$(AM_CFLAGS)' \
     252        && ./build.sh \
     253        && ./make $(AM_MAKEFLAGS) check \
     254        && rm -f *.o make \
     255        && $(NR_MAKE) $(AM_MAKEFLAGS) \
     256        && ./make $(AM_MAKEFLAGS) check
     257
     258
    195259## --------------- ##
    196260## Sanity checks.  ##
    197261## --------------- ##
    198262
    199 # Checks that don't require cvs.  Run `changelog-check' last as
     263# Before we build a distribution be sure we run our local checks
     264#distdir: local-check
     265
     266.PHONY: local-check po-check changelog-check
     267
     268# Checks that don't require Git.  Run 'changelog-check' last as
    200269# previous test may reveal problems requiring new ChangeLog entries.
    201270local-check: po-check changelog-check
     
    212281
    213282# Verify that all source files using _() are listed in po/POTFILES.in.
    214 # Ignore make.h; it defines _().
     283# Ignore makeint.h; it defines _().
    215284po-check:
    216285        if test -f po/POTFILES.in; then \
    217286          grep '^[^#]' po/POTFILES.in | sort > $@-1; \
    218           $(PERL) -wn -e 'if (/\b_\(/) { $$ARGV eq "make.h" || print "$$ARGV\n" and close ARGV }' *.c *.h | sort > $@-2; \
     287          $(PERL) -wn -e 'if (/\b_\(/) { $$ARGV eq "./makeint.h" || print "$$ARGV\n" and close ARGV }' `find . -name '*.[ch]'` | sed 's,^\./,,' | sort > $@-2; \
    219288          diff -u $@-1 $@-2 || exit 1; \
    220289          rm -f $@-1 $@-2; \
    221290        fi
    222291
     292
     293## --------------- ##
     294## Generate docs.  ##
     295## --------------- ##
     296
     297.PHONY: update-makeweb gendocs
     298
     299CVS = cvs
     300
     301makeweb-repo = $(USER)@cvs.sv.gnu.org:/web/make
     302gnuweb-repo = :pserver:anonymous@cvs.sv.gnu.org:/web/www
     303gnuweb-dir = www/server/standards
     304
     305# Get the GNU make web page boilerplate etc.
     306update-makeweb:
     307        [ -d '$(MAKEWEBDIR)' ] || mkdir -p '$(MAKEWEBDIR)'
     308        [ -d '$(MAKEWEBDIR)'/CVS ] \
     309            && { cd '$(MAKEWEBDIR)' && $(CVS) update; } \
     310            || { mkdir -p '$(dir $(MAKEWEBDIR))' && cd '$(dir $(MAKEWEBDIR))' \
     311                 && $(CVS) -d $(makeweb-repo) co -d '$(notdir $(MAKEWEBDIR))' make; }
     312
     313# Get the GNU web page boilerplate etc.
     314update-gnuweb:
     315        [ -d '$(GNUWEBDIR)' ] || mkdir -p '$(GNUWEBDIR)'
     316        [ -d '$(GNUWEBDIR)/$(gnuweb-dir)'/CVS ] \
     317            && { cd '$(GNUWEBDIR)/$(gnuweb-dir)' && $(CVS) update; } \
     318            || { cd '$(GNUWEBDIR)' && $(CVS) -d $(gnuweb-repo) co '$(gnuweb-dir)'; }
     319
     320gendocs: update-gnuweb update-makeweb
     321        cp $(GNULIBDIR)/doc/gendocs_template doc
     322        cd doc \
     323          && rm -rf doc/manual \
     324          && $(GNULIBDIR)/build-aux/gendocs.sh --email '$(BUGLIST)' \
     325                make 'GNU Make Manual'
     326        find '$(MAKEWEBDIR)'/manual \( -name CVS -prune \) -o \( -name '[!.]*' -type f -exec rm -f '{}' \; \)
     327        cp -r doc/manual '$(MAKEWEBDIR)'
     328        @echo 'Status of $(MAKEWEBDIR) repo:' && cd '$(MAKEWEBDIR)' \
     329            && cvs -q -n update | grep -v '^M ' \
     330            && echo '- cvs add <new files>' \
     331            && echo '- cvs remove <deleted files>' \
     332            && echo '- cvs commit' \
     333            && echo '- cvs tag make-$(subst .,-,$(VERSION))'
     334
     335## ------------------------- ##
     336## Make release targets.     ##
     337## ------------------------- ##
     338
     339.PHONY: tag-release
     340tag-release:
     341        case '$(VERSION)' in \
     342            (*.*.9*) message=" candidate" ;; \
     343            (*)      message= ;; \
     344        esac; \
     345        $(GIT) tag -m "GNU Make release$$message $(VERSION)" -u '$(GPG_FINGERPRINT)' '$(VERSION)'
     346
    223347## ------------------------- ##
    224348## GNU FTP upload artifacts. ##
     
    230354
    231355GPG = gpg
    232 GPGFLAGS = -u 6338B6D4
     356GPGFLAGS = -u $(GPG_FINGERPRINT)
    233357
    234358DIST_ARCHIVES_SIG = $(addsuffix .sig,$(DIST_ARCHIVES))
     
    267391
    268392
    269 # Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
    270 # 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
     393# Rebuild Makefile.in if this file is modifed.
     394Makefile.in: maintMakefile
     395
     396# Copyright (C) 1997-2016 Free Software Foundation, Inc.
    271397# This file is part of GNU Make.
    272398#
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette