CATEGORII DOCUMENTE |
Asp | Autocad | C | Dot net | Excel | Fox pro | Html | Java |
Linux | Mathcad | Photoshop | Php | Sql | Visual studio | Windows | Xml |
make |
make [options] [targets] [macro definitions] Update one or more targets according to dependency instructions in a description file in the current directory. By default, this file is called makefile or Makefile. Options, targets, and macro definitions can be in any order. Macros definitions are typed as: name=stringFor more information on make, see Managing Projects with make by Andrew Oram and Steve Talbott. Options-d, --debug Print detailed debugging information. -e, --environment-overrides Override makefile macro definitions with environment variables. -f makefile, --file=makefile, --makefile=makefile Use makefile as the description file; a filename of denotes standard input. -h, --help Print options to make command. -i, --ignore-errors Ignore command error codes (same as .IGNORE). -j [jobs], --jobs [=jobs Attempt to execute jobs jobs simultaneously, or, if no number is specified, as many jobs as possible. -k, --keep-going Abandon the current target when it fails, but keep working with unrelated targets. -l [load], --load-average [=load], --max-load [=load Attempt to keep load below load, which should be a floating-point number. Used with -j. -n, --just-print, --dry-run, --recon Print commands but don't execute (used for testing). -o file, --old-file=file, --assume-old=file Never remake file or cause other files to be remade on account of it. -p, --print-data-base Print rules and variables in addition to normal execution. -q, --question Query; return 0 if file is up-to-date; nonzero otherwise. -r, --no-built-in-rules Do not use default rules. -s, --silent, --quiet Do not display command lines (same as .SILENT). -t, --touch Touch the target files, without remaking them. -v, --version Show version of make. -w, --print-directory Display the current working directory before and after execution. --warn -undefined -variables Print warning if a macro is used without being defined. -C directory, --directory directory cd to directory before beginning make operations. A subsequent -C directive will cause make to attempt to cd into a directory relative to the current working directory. -I directory, --include-dir directory Include directory in list of directories that contain included files. -S, --no-keep-going, --stop Cancel previous -k options. Useful in recursive makes. -W file, --what-if file, --new-file file, --assume-new file Behave as though file has been recently updated. Description file linesInstructions in the description file are interpreted as single lines. If an instruction must span more than one input line, use a backslash () at the end of the line so that the next line is considered as a continuation. The description file may contain any of the following types of lines: Blanklines Blank lines are ignored. Commentlines A pound sign (#) can be used at the beginning of a line or anywhere in the middle. make ignores everything after the #. Dependencylines Depending on one or more targets, certain commands that follow will be executed. Possible formats include: targets : dependenciestargets : dependencies ; command Subsequent commands are executed if dependency files (the names of which may contain wildcards) do not exist or are newer than a target. If no prerequisites are supplied, then subsequent commands are always executed (whenever any of the targets are specified). No tab should precede any targets. Suffixrules These specify that files ending with the first suffix can be prerequisites for files ending with the second suffix (assuming the root filenames are the same). Either of these formats can be used: .suffix.suffix:.suffix: The second form means that the root filename depends on the filename with the corresponding suffix. Commands Commands are grouped below the dependency line and are typed on lines that begin with a tab. If a command is preceded by a hyphen (-), make ignores any error returned. If a command is preceded by an at sign (@), the command line won't echo on the display (unless make is called with -n). macrodefinitions These have the following form: name = stringor define namestring endef Blank space is optional around the =. includestatements Similar to the C include directive, these have the form: include filesInternal macrosThe list of prerequisites that have been changed more recently than the current target. Can be used only in normal description file entries -- not suffix rules. The name of the current target, except in description file entries for making libraries, where it becomes the library name. Can be used both in normal description file entries and in suffix rules. $< The name of the current prerequisite that has been modified more recently than the current target. The name -- without the suffix -- of the current prerequisite that has been modified more recently than the current target. Can be used only in suffix rules. The name of the corresponding .o file when the current target is a library module. Can be used both in normal description file entries and in suffix rules. A space-separated list of all dependencies, with no duplications. A space-separated list of all dependencies, including duplications. Pattern rulesThese are a more general application of the idea behind suffix rules. If a target and a dependency both contain %, GNU make will substitute any part of an existing filename. For instance, the standard suffix rule: can be written as the following pattern rule: %.o : %.c$(cc) -o $@ $< Macro modifiersD The directory portion of any internal macro name except $?. Valid uses are: $(*D) $$(@D) $(?D) $(<D) $(%D) $(@D) $(^D) F The file portion of any internal macro name except $?. Valid uses are: $(*F) $$(@F) $(?F) $(<F) $(%F) $(@F) $(^F) Functions$(subst from to string Replace all occurrences of from with to in string. $(patsubst pattern to string Similar to subst, but treat % as a wildcard within pattern. Substitute to for any word in string that matches pattern. $(strip string Remove all extraneous whitespace. $(findstring substring mainstring Return substring if it exists within mainstring; otherwise, return null. $(filter pattern string Return those words in string that match at least one word in pattern. patterns may include the wildcard %. $(filter-out pattern string Remove those words in string that match at least one word in pattern. patterns may include the wildcard %. $(sort list Return list, sorted in lexical order. $(dir list Return the directory part (everything up to the last slash) of each filename in list. $(notdir list Return the nondirectory part (everything after the last slash) of each filename in list. $(suffix list Return the suffix part (everything after the last period) of each filename in list. $(basename list Return everything but the suffix part (everything up to the last period) of each filename in list. $(addsuffix suffix list Return each filename given in list with suffix appended. $(addprefix prefix list Return each filename given in list with prefix prepended. $(join list1 list2 Return a list formed by concatenating the two arguments, word by word (e.g., $(join a b,.c .o) becomes a.c b.o). $(word n string Return the nth word of string. $(words string Return the number of words in string. $(firstword list Return the first word in the list list. $(wildcard pattern Return a list of existing files in the current directory that match pattern. $(origin variable Return one of the following strings that describes how variable was defined: undefined, default, environment, environment override, file, command line, override, or automatic. $(shell command Return the results of command. Any newlines in the result are to be converted to spaces. This function works similarly to backquotes in most shells. Macro string substitutionmacro s1 s2 Evaluates to the current definition of $(macro), after substituting the string s2 for every occurrence of s1 that occurs either immediately before a blank or tab or at the end of the macro definition. Special target names.DEFAULT: Commands associated with this target are executed if make can't find any description file entries or suffix rules with which to build a requested target. .EXPORT_ALL_VARIABLES: If this target exists, export all macros to all child processes. .IGNORE: Ignore error codes. Same as the -i option. .PHONY: Always execute commands under a target, even if it is an existing, up-to-date file. .PRECIOUS: Files you specify for this target are not removed when you send a signal (such as an interrupt) that aborts make or when a command line in your description file returns an error. .SILENT: Execute commands, but do not echo them. Same as the -s option. .SUFFIXES: Suffixes associated with this target are meaningful in suffix rules. If no suffixes are listed, the existing list of suffix rules is effectively 'turned off.' |
Politica de confidentialitate | Termeni si conditii de utilizare |
Vizualizari: 685
Importanta:
Termeni si conditii de utilizare | Contact
© SCRIGROUP 2024 . All rights reserved