aboutsummaryrefslogtreecommitdiff
path: root/bin/sh/Makefile
Commit message (Collapse)AuthorAgeFilesLines
* Bump WARNS for sh(1).Edward Tomasz Napierala2020-04-011-2/+0
| | | | | | | | | | Reviewed by: jilles MFC after: 2 weeks Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D24181 Notes: svn path=/head/; revision=359511
* Fix .depend files to work for build tools.Bryan Drewery2019-06-151-0/+1
| | | | | | | | | | This is somewhat of a follow-up to r335746. MFC after: 2 weeks Sponsored by: DellEMC Notes: svn path=/head/; revision=349062
* Install .shrc for root, and set PS1 for the toor account.Edward Tomasz Napierala2019-01-241-3/+6
| | | | | | | | | | Reviewed by: jilles MFC after: 2 weeks Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D18872 Notes: svn path=/head/; revision=343416
* Finish moving dot.cshrc and dot.profile to bin/csh/ and bin/sh/.Brad Davis2018-08-291-1/+9
| | | | | | | | Approved by: re (gjb), will (mentor) Differential Revision: https://reviews.freebsd.org/D16770 Notes: svn path=/head/; revision=338374
* Revert parts of r337849 and r337857Brad Davis2018-08-151-9/+1
| | | | | | | | | | | | This fixes the build and I will redo these changes as part of a future review that organizes them differently. The way I tried to do it here could be done better. Sorry for the noise. Approved by: will (mentor) Differential Revision: https://reviews.freebsd.org/D16737 Notes: svn path=/head/; revision=337882
* Fix build after r337849Brad Davis2018-08-151-1/+3
| | | | | | | | | | | | This moves the symlink creation to after where the files are installed. This also inverts the shell change so that it only happens if MK_TCSH is on. Approved by: will (mentor) Differential Revision: https://reviews.freebsd.org/D16725 Notes: svn path=/head/; revision=337857
* Move all sh and csh files into bin/sh/ or bin/csh/Brad Davis2018-08-151-0/+7
| | | | | | | | | | | This simplifies pkgbase by migrating these to CONFS so they are properly tagged as config files. Approved by: will (mentor) Differential Revision: https://reviews.freebsd.org/D16708 Notes: svn path=/head/; revision=337849
* Stop building intermediate .o files.Bryan Drewery2018-06-271-9/+2
| | | | | | | | | | | | These are not used to link the final tool anymore. At some point in the past the suffix rules changed to not link these in. The original reason for this in r19176 is unclear but seems to be related to mkdep. The .depend handling is still broken here as it is for all build tool patterns like this. Sponsored by: Dell EMC Notes: svn path=/head/; revision=335746
* MFhead@r321912Enji Cooper2017-08-021-1/+1
|\ | | | | | | Notes: svn path=/projects/make-check-sandbox/; revision=321913
| * Convert traditional ${MK_TESTS} conditional idiom for including testEnji Cooper2017-08-021-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | directories to SUBDIR.${MK_TESTS} idiom This is being done to pave the way for future work (and homogenity) in ^/projects/make-check-sandbox . No functional change intended. MFC after: 1 weeks Notes: svn path=/head/; revision=321912
* | Add HAS_TESTS to all Makefiles that use the SUBDIR.${MK_TESTS}+= tests idiomEnji Cooper2017-08-021-3/+2
|/ | | | Notes: svn path=/projects/make-check-sandbox/; revision=321911
* bin: normalize paths using SRCTOP-relative paths or :H when possibleEnji Cooper2017-03-041-3/+3
| | | | | | | | | | This simplifies make logic/output MFC after: 1 month Sponsored by: Dell EMC Isilon Notes: svn path=/head/; revision=314655
* WITH_META_MODE: Don't expect meta files for side-effect generated files.Bryan Drewery2016-06-031-0/+3
| | | | | | | | | | | | The first file in these lists will generate everything else so only it should be getting a .meta file. With bmake's missing=yes meta feature these would otherwise cause a rebuild without the .NOMETA hint. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=301285
* DIRDEPS_BUILD: Run the staged bootstrap-tools version of build-tools.Bryan Drewery2016-05-091-2/+2
| | | | | | | | | This avoids running target binaries. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=299289
* MFHGlen Barber2016-04-161-3/+3
|\ | | | | | | | | | | | | Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=298092
| * META_MODE: Don't rebuild build-tools targets during normal build.Bryan Drewery2016-04-141-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | This avoids 'build command changed' due to CFLAGS/CC changes during the normal build. Without this the build-tools targets end up rebuilding for the *target* rather than keeping the native versions built in build-tools. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=297997
* | Explicitly add unmarked bin/ binaries to the runtime package.Glen Barber2016-02-091-0/+1
|/ | | | | | | | | | | Note: tcsh(1) has a MK_TCSH=no test, so this should be a separate package, which requires pre-install/post-install scripts, to be added later. Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=295439
* Convert bin/ to LIBADD, reduce overlinking allow to build all components asBaptiste Daroussin2014-11-251-2/+1
| | | | | | | static Notes: svn path=/head/; revision=275028
* Replace all uses of libncurses and libtermcap with their wide characterBrooks Davis2014-07-171-2/+2
| | | | | | | | | | | | | variants. This allows usable file system images (i.e. those with both a shell and an editor) to be created with only one copy of the curses library. Exp-run: antoine PR: 189842 Discussed with: bapt Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=268804
* Use src.opts.mk in preference to bsd.own.mk except where we need stuffWarner Losh2014-05-061-1/+1
| | | | | | | from the latter. Notes: svn path=/head/; revision=265420
* Migrate tools/regression/bin/ tests to the new layout.Julio Merino2013-12-111-2/+5
| | | | | | | | | | | | | | | | | | | | | | | This change is a proof of concept on how to easily integrate existing tests from the tools/regression/ hierarchy into the /usr/tests/ test suite and on how to adapt them to the new layout for src. To achieve these goals, this change: - Moves tests from tools/regression/bin/<tool>/ to bin/<tool>/tests/. - Renames the previous regress.sh files to legacy_test.sh. - Adds Makefiles to build and install the tests and all their supporting data files into /usr/tests/bin/. - Plugs the legacy_test test programs into the test suite using the new TAP backend for Kyua (appearing in 0.8) so that the code of the test programs does not have to change. - Registers the new directories in the BSD.test.dist mtree file. Reviewed by: freebsd-testing Approved by: rpaulo (mentor) Notes: svn path=/head/; revision=259210
* sh: Remove mkinit.Jilles Tjoelker2013-07-251-8/+3
| | | | | | | | | | | | | | | | | Replace the RESET blocks with regular functions and a reset() function that calls them all. This code generation tool is unusual and does not appear to provide much benefit. I do not think isolating the knowledge about which modules need to be reset is worth an almost 500-line build tool and wider scope for variables used by the reset functions. Also, relying on reset functions is often wrong: the cleanup should be done in exception handlers so that no stale state remains after 'command eval' and the like. Notes: svn path=/head/; revision=253650
* Work better with how make/bmake works:Marcel Moolenaar2012-05-241-1/+1
| | | | | | | | | | | | | | | 1. Avoid a cd back into ${.CURDIR} to run mkbuiltins when we know make will first cd into ${.OBJDIR}. Keep the cwd to what make sets it to. 2. Don't tell mkbuiltins where to write to (= ${.OBJDIR}), but where to get sources from (= ${.CURDIR}). This to compensate for point 1. This fixes a problem with bmake's mk files that optimize ${.OBJDIR} to expand to "." after changing cwd, not taking into account that the target is pretty much undoing that and not getting the full path to the object tree anymore. Notes: svn path=/head/; revision=235927
* sh: Import arithmetic expression code from dash.Jilles Tjoelker2011-02-081-5/+5
| | | | | | | | | | | | | | | | | | | New features: * proper lazy evaluation of || and && * ?: ternary operator * executable is considerably smaller (8K on i386) because lex and yacc are no longer used Differences from dash: * arith_t instead of intmax_t * imaxdiv() not used * unset or null variables default to 0 * let/exp builtin (undocumented, will probably be removed later) Obtained from: dash Notes: svn path=/head/; revision=218466
* sh: Add kill builtin.Jilles Tjoelker2010-12-211-1/+2
| | | | | | | | | | | | | | | | | | | | This allows specifying a %job (which is equivalent to the corresponding process group). Additionally, it improves reliability of kill from sh in high-load situations and ensures "kill" finds the correct utility regardless of PATH, as required by POSIX (unless the undocumented %builtin mechanism is used). Side effect: fatal errors (any error other than kill(2) failure) now return exit status 2 instead of 1. (This is consistent with other sh builtins, but not in NetBSD.) Code size increases about 1K on i386. Obtained from: NetBSD Notes: svn path=/head/; revision=216629
* sh: Add printf builtin.Jilles Tjoelker2010-11-191-2/+3
| | | | | | | | | | | | | | | | | | | | This was removed in 2001 but I think it is appropriate to add it back: * I do not want to encourage people to write fragile and non-portable echo commands by making printf much slower than echo. * Recent versions of Autoconf use it a lot. * Almost no software still wants to support systems that do not have printf(1) at all. * In many other shells printf is already a builtin. Side effect: printf is now always the builtin version (which behaves identically to /usr/bin/printf) and cannot be overridden via PATH (except via the undocumented %builtin mechanism). Code size increases about 5K on i386. Embedded folks might want to replace /usr/bin/printf with a hard link to /usr/bin/alias. Notes: svn path=/head/; revision=215520
* We only need to look as far as '..' to find 'test/'.David E. O'Brien2010-10-131-1/+1
| | | | Notes: svn path=/head/; revision=213815
* In the spirit of r90111, depend on c89 and remove the "STATIC" macroDavid E. O'Brien2010-10-131-1/+1
| | | | | | | and its usage. Notes: svn path=/head/; revision=213811
* If one wishes to set breakpoints of static the functions here, theyDavid E. O'Brien2010-10-131-1/+1
| | | | | | | | | cannot be inlined. Submitted by: jhb Notes: svn path=/head/; revision=213798
* Suggest that DEBUG_FLAGS be used to enable extra debugging rather thanJohn Baldwin2010-10-131-1/+1
| | | | | | | | | | frobbing CFLAGS directly. DEBUG_FLAGS is something that can be specified on the make command line without having to edit the Makefile directly. Submitted by: Garrett Cooper Notes: svn path=/head/; revision=213774
* If DEBUG is 3 or greater, disable STATICization of functions.David E. O'Brien2010-10-121-1/+1
| | | | | | | Also correct the documented location of the trace file. Notes: svn path=/head/; revision=213744
* Allow one to regression test 'sh' changes without having to installDavid E. O'Brien2010-10-121-0/+3
| | | | | | | a potentially bad /bin/sh first. Notes: svn path=/head/; revision=213738
* Reduce the WARNS level to avoid a compiler warning about a variableJohn Birrell2007-11-181-1/+1
| | | | | | | possibly being clobbered by a longjmp or a fork with gcc4. Notes: svn path=/head/; revision=173718
* Whitespace nits.Jens Schweikhardt2006-04-171-1/+1
| | | | Notes: svn path=/head/; revision=157811
* Recent cleanups made it possible to bump WARNS to 3.Stefan Farfeleder2005-08-141-1/+1
| | | | Notes: svn path=/head/; revision=149046
* Install /bin/sh safely. This allows a shell script to be usedRuslan Ermilov2004-03-181-0/+1
| | | | | | | | | | to strip binaries by specifying it in the STRIPBIN environment variable honoured by install(1). MFC after: 3 days Notes: svn path=/head/; revision=127167
* style.Makefile:Johan Karlsson2004-02-231-1/+1
| | | | | | | Use WARNS?= instead of WARNS= Notes: svn path=/head/; revision=126173
* Fixed style of DPADD and LDADD assignments as per style.Makefile(5).Ruslan Ermilov2004-02-051-2/+2
| | | | Notes: svn path=/head/; revision=125503
* Removed duplicate y.tab.h from SRCS and CLEANFILES.Ruslan Ermilov2004-01-201-1/+1
| | | | Notes: svn path=/head/; revision=124751
* The is_name and is_in_name macros are FUBAR'ed.David E. O'Brien2003-05-021-0/+2
| | | | | | | | | Due to the use of signed vs. unsigned chars on our various platforms, one gets "warning: comparison is always true due to limited range of data type" from GCC 3.3. Notes: svn path=/head/; revision=114500
* It is now safe to remove WARNS=0 and WFORMAT=0.Maxime Henrion2002-10-011-2/+0
| | | | | | | Tested on: alpha, i386, sparc64 Notes: svn path=/head/; revision=104284
* Add back WARNS=0 and WFORMAT=0; gcc is finding nonexistent format stringTim J. Robbins2002-10-011-0/+2
| | | | | | | errors with %qd formats. Notes: svn path=/head/; revision=104276
* Remove WARNS=0 and WFORMAT=0. The shell compiles cleanly at WARNS=2Tim J. Robbins2002-10-011-2/+0
| | | | | | | | on at least i386. If there are warnings on other archs, I'd rather hear about them than pretend they didn't exist. Notes: svn path=/head/; revision=104273
* Lock down with WFORMAT=1 except those directories with unfixed warnings.Kris Kennaway2002-02-041-0/+1
| | | | | | | Tested on i386 and alpha. Notes: svn path=/head/; revision=90166
* Default to WARNS=2. Binary builds that cannot handle this must explicitlyDavid E. O'Brien2001-12-041-0/+1
| | | | | | | | | set WARNS=0. Reviewed by: mike Notes: svn path=/head/; revision=87323
* Remove the printf builtin command from sh(1), which command is notAkinori MUSHA2001-11-201-3/+2
| | | | | | | | | | | | | | | used so often that it's worth keeping it as a builtin. Now that all the printf invocations from within the system startup scripts, we can safely remove it. Urged by: sheldonh :) No MFC is planned so far because it may break compatibility and violate POLA. Notes: svn path=/head/; revision=86692
* Make test(1) a builtin command of our sh(1) for efficiency. TheAkinori MUSHA2001-11-171-2/+4
| | | | | | | | | | | | | | binary size increase is 3,784 bytes (about 0.6%). I don't drop the printf builtin while I'm here because some /etc/rc.* scripts seem to use it before mounting /usr where printf(1) resides. Reviewed by: arch (sheldonh) Inspired by: NetBSD, ksh Clued by: ume (on how the printf builtin is used) Notes: svn path=/head/; revision=86505
* Improve shell documentation:Sheldon Hearn1999-09-081-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Consistently misspell built-in as builtin. * Add a builtin(1) manpage and create builtin(1) MLINKS for all shell builtin commands for which no standalone utility exists. These MLINKS replace those that were created for csh(1). * Add appropriate xrefs for builtin(1) to the csh(1) and sh(1) manpages, as well as to the manpages of standalone utilities which are supported as shell builtin commands in at least one of the shells. In such manpages, explain that similar functionality may be provided as a shell builtin command. * Improve sh(1)'s description of the cd builtin command. Csh(1) already describes it adequately. Replace the cd(1) manpage with a builtin(1) MLINKS link. * Clean up some mdoc problems: use Xr instead of literal "foo(n)"; use Ic instead of Xr for shell builtin commands. * Undo English contractions. Reviewed by: mpp, rgrimes Notes: svn path=/head/; revision=51090
* $Id$ -> $FreeBSD$Peter Wemm1999-08-271-1/+1
| | | | Notes: svn path=/head/; revision=50471
* Added a `build-tools' target for internal tools.Bruce Evans1998-07-071-4/+3
| | | | | | | | | Removed explicit dependencies of foo.o on foo.c. These were mainly placeholders for comments about missing dependencies of tools objects on headers. This problem needs to be handled more generally. Notes: svn path=/head/; revision=37456