Commit Graph

129 Commits

Author SHA1 Message Date
William Hubbs
92e6bdee12 Use _BSD_SOURCE on FreeBSD 2018-03-14 13:07:46 -05:00
William Hubbs
71f275b2aa typo fix 2018-03-14 10:45:40 -05:00
William Hubbs
6dc0d0af33 Remove _XOPEN_SOURCE macros from builds 2018-03-13 18:14:55 -05:00
William Hubbs
59a9e53378 Add _POSIX_C_SOURCE macro to FreeBSD build 2018-03-13 18:04:54 -05:00
William Hubbs
109869641f fix build on FreeBSD 2018-03-01 11:47:29 -06:00
William Hubbs
6c456f9383 Add zsh-completion support 2017-12-07 11:30:32 -06:00
William Hubbs
d220fc2723 add bash completion support
This fixes #188.
2017-12-06 13:25:26 -06:00
Sergei Trofimovich
688566c535 mk/cc.mk: make implicit function declarations fatal (#136)
Avoids issues with missing prototypes causing truncation of pointers.

Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
2017-05-30 03:51:42 -04:00
William Hubbs
9047ea4cb0 install support files
These files have been in the distribution for some time but haven't been
installed. They are good examples of how to do things, so we should
install them.
2017-02-18 15:52:28 -06:00
Benda Xu
074d90f5a4 Drop the use of the _BSD_SOURCE macro on Linux
X-Gentoo-Bug: 604666
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=604666
2017-01-04 16:59:24 -06:00
Benda Xu
7056b56b3c Drop the use of the _BSD_SOURCE macro on GNU/Hurd
X-Gentoo-Bug: 604666
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=604666
2017-01-04 16:58:52 -06:00
William Hubbs
24010dcb48 dist: convert to tar.gz
This allows the "make dist" target to be used as well as the github
archive generation.
2016-09-23 15:28:56 -05:00
Julian Ospald
8bca2cd4b3 Build: fix hardcoded pkg-config invocation
This fixes #89.
2016-07-13 16:52:05 -05:00
Benda Xu
5af5d12f3e Fix PATH for Prefix.
1. remove default /bin:/sbin:/usr/bin:/usr/sbin
2. PKG_PREFIX should be defaulted to $(PREFIX)/usr
3. LOCAL_PREFIX should be defaulted to $(PREFIX)/usr/local

X-Gentoo-Bug:583634
X-Gentoo-Bug-URL:https://bugs.gentoo.org/show_bug.cgi?id=583634
2016-06-13 17:43:36 -05:00
William Hubbs
000503fad7 Convert OpenRC to a centralized copyright/license structure
In the past, OpenRC was a hybrid of a centralized and file-scope
license/copyright structure.

I followed the instructions from the Software Freedom Law Center [1] to
convert to a Centralized structure where possible, for easier future
maintenance.

[1] https://softwarefreedom.org/resources/2012/ManagingCopyrightInformation.html
2015-12-21 12:16:06 -06:00
William Hubbs
9225bfa691 Build: make snapshot remove .git directory from tarball 2015-05-01 10:14:31 -05:00
William Hubbs
a27d577da8 Build: fix the dist target
The dist target now creates an archive based on the version setting.
This makes it possible to create an archive identical to the ones github
generates once the release is tagged.
2015-04-30 14:45:42 -05:00
William Hubbs
de93587aff Silence warning about _DEFAULT_SOURCE for Linux/glibc
In >=glibc-2.20, the _BSD_SOURCE macro is deprecated in favor of
_DEFAULT_SOURCE. This adds -D_DEFAULT_SOURCE to CPPFLAGS on Linux.

Fixes #44
2015-03-24 17:46:30 +00:00
William Hubbs
e16b7183e9 mk/os-GNU.mk: fix typo
MAX_PATH should have been PATH_MAX
2015-03-21 22:49:56 -05:00
William Hubbs
423f82bae9 ChangeLog: show authors and committers 2015-02-18 12:47:19 -06:00
Will Miles
3f80f22e22 Prioritize local includes and libraries
This fixes #35.
2015-01-24 13:48:53 -06:00
William Hubbs
6a9679377f Do not call the shell to evaluate CHANGELOG_LIMIT
The git log command understands dates such as "1 year ago", so there is
no need to use the date command.
2014-12-08 09:47:42 -06:00
William Hubbs
3647db7a27 Add target to create ChangeLog
This was added by request because some users are requesting a ChangeLog.

This fixes #29.
2014-12-07 17:16:48 -06:00
William Hubbs
7a92eb8887 rename git.mk to gitver.mk
This is a more descriptive name since this file only sets the gitver
variable.
2014-12-05 11:55:45 -06:00
Jason Zaman
1932360adc Integrate the functionality from runscript_selinux.so
runscript used to dlopen() runscript_selinux.so. This adds equivalent
functionality directly in to runscript instead. It authenticates with
either PAM or shadow and optionally has a dep on audit.

X-Gentoo-Bug: 517450
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=517450
2014-11-03 09:31:25 -06:00
Johan Bergström
ba0a11fc94 Pass ncurses cflags to build
Fixes #25
Note from William Hubbs:
The original patch overwrote CFLAGS. I modified this patch to add the
ncurses cflags to CPPFLAGS instead of overwriting CFLAGS.
2014-10-26 13:04:20 -05:00
Svante Signell
203b754f84 add missing files for GNU/Hurd 2014-10-23 13:00:24 -05:00
Gabriele Giacone
d8e1d9a6ed Add missing files for GNU/kFreeBSD 2014-10-22 11:09:58 -05:00
William Hubbs
4a1afa694c Add SELinux support to the build system
X-Gentoo-Bug: 516956
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=516956
2014-07-15 11:38:19 -05:00
Steven Chamberlain
766d71c2d3 Begin port to GNU/kFreeBSD
This is just a minimal port to get Debian up and running; the rest will
be done later.
2013-10-30 01:40:03 -05:00
William Hubbs
838c9efb36 Remove gentoo's net.* scripts
It has been determined that it will be best for gentoo's net.* scripts
to be in a separate package to allow independent development.
This package will be called netifrc and maintained by Gentoo.
2013-08-13 16:33:41 -05:00
Gary
9ebd5a6aff Add support for DragonFly BSD 2013-07-25 22:33:24 -05:00
Andrew Gregory
8c90042dee make BINDIR and SBINDIR available to input files
BINDIR and SBINDIR can be set independently of PREFIX and may not be set
to PREFIX/bin as scripts currently assume.

Note from William Hubbs:

This adds @BINDIR@ and @SBINDIR@ macros to the sed commands run to
convert *.in files to the executable form.
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
2013-02-23 20:30:39 -06:00
Andrew Gregory
9eb0674512 add SBINDIR variable to sys.mk
BINDIR was pointing to PREFIX/sbin which was confusing and inconsistent
with src/rc/Makefile.  Add SBINDIR and redefine BINDIR appropriately.

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
2013-02-23 20:30:39 -06:00
William Hubbs
549cbadd2c build: use pkg-config to find ncurses libraries if it is available
If ncurses was built with the --with-termlib switch enabled, tgoto, tgetent
and tgetstr move to libtinfo. Fortunately, ncurses provides a pkg-config
file which we can use if pkg-config is installed. If it is not, we still
link to -lncurses for now, so pkg-config is not a hard requirement.

Reported-by: jan.paesmans@gmail.com
X-Gentoo-Bug: 455912
X-Gentoo-Bug: https://bugs.gentoo.org/show_bug.cgi?id=455912
2013-02-23 17:10:35 -06:00
William Hubbs
8e4169e29e Fix UPREFIX for Gentoo Prefix installations
Make sure UPREFIX in our make files gets set correctly when
MKPREFIX=yes. In this situation, UPREFIX should be ${PREFIX}/usr.

Reported-by: <heroxdb@gentoo.org>
X-Gentoo-Bug: 415899
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=415899
2012-08-31 16:50:49 -05:00
William Hubbs
ea696b47c8 fix typo 2012-08-31 14:47:20 -05:00
William Hubbs
9e88d73aaa add MKPREFIX flag to build system
This allows building OpenRC for a Gentoo Prefix installation.
2012-08-31 10:40:47 -05:00
William Hubbs
32c506a4c8 Drop rc_sys definition from build system 2012-02-20 20:13:11 -06:00
Robin H. Johnson
5021c119c7 sysctl.d: Include a README file for /etc/sysctl.d/
Our sysctl script has read from /etc/sysctl.d/ but the directory was not
created by default, and we didn't document it.

X-Gentoo-Bug: 398189
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=398189
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
2012-02-09 01:49:04 -08:00
Robin H. Johnson
e3d0fe06bd Respin features.h usage so that we correctly test for features before we use them. Some BSD libc implementations may have one or the other flag, but not both.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
2012-01-23 05:26:40 +00:00
Christian Ruppert
2990e5a2e3 Whitespace 2012-01-22 01:17:42 +01:00
William Hubbs
9a3d6c7600 Add MKSTATICLIBS switch
The MKSTATICLIBS switch, which defaults to yes, controls whether or not
static libraries are built and installed.

Reported-by: Agostino Sarubbo <ago@autistici.org>
x-Gentoo-Bug: 378267
x-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=378267
2011-11-18 08:55:30 -06:00
William Hubbs
5066d40ac8 Use pattern rules instead of suffix rules
Rework the makefiles to use pattern rules instead of suffix rules.
This is the preferred way to write implicit rules according to the gnu
make manual.
2011-10-29 09:43:24 -05:00
Mike Frysinger
9a539ebbe1 further clean up OS differences in makefiles
No need for if() logic.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-10-20 14:32:37 -05:00
Mike Frysinger
d0bc4f20ad drop useless "All rights reserved" notice
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-06-29 19:46:31 -04:00
Mike Frysinger
227f831639 cc.mk: move debug.mk out of end Makefiles
Since we always want debug.mk whenever we include cc.mk, move the include
out of the Makefiles and into cc.mk itself.  This also fixes an include
order bug in rc/Makefile where debug.mk is included before cc.mk and
breaks the default CFLAGS setup in cc.mk.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-05-28 12:00:34 -04:00
Mike Frysinger
98d3b407fe cc.mk: enable -g by default
Can do no harm!

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-05-28 12:00:13 -04:00
William Hubbs
67640d2d97 remove hard coded directory paths from link flags
Currently, we do not see a reason for these, and it causes an issue for
cross compilation.

X-Gentoo-Bug: 361465
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=361465
2011-04-01 17:32:12 -05:00
William Hubbs
3fca6bd027 allow default rc_sys value to be set at build time
This allows the default value of rc_sys to be set when openrc is
compiled. This will allow openrc to be installed, e.g. on vserver guests
and will allow them to be rebooted without the need to edit rc.conf.

This patch is a combined effort between myself and Robin Johnson.

X-Gentoo-Bug: 357247
X-Gentoo-Bug-URL: http://bugs.gentoo.org/show_bug.cgi?id=357247
2011-03-05 00:04:06 -06:00