diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-fs/multipath-tools | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sys-fs/multipath-tools')
-rw-r--r-- | sys-fs/multipath-tools/Manifest | 1 | ||||
-rw-r--r-- | sys-fs/multipath-tools/files/multipath-tools-0.5.0-makefile.patch | 200 | ||||
-rw-r--r-- | sys-fs/multipath-tools/files/multipath-tools-0.5.0-systemd-pkgconfig.patch | 24 | ||||
-rwxr-xr-x | sys-fs/multipath-tools/files/multipath.rc | 27 | ||||
-rw-r--r-- | sys-fs/multipath-tools/files/rc-multipathd | 21 | ||||
-rw-r--r-- | sys-fs/multipath-tools/metadata.xml | 5 | ||||
-rw-r--r-- | sys-fs/multipath-tools/multipath-tools-0.5.0-r1.ebuild | 66 |
7 files changed, 344 insertions, 0 deletions
diff --git a/sys-fs/multipath-tools/Manifest b/sys-fs/multipath-tools/Manifest new file mode 100644 index 000000000000..23af9e77a811 --- /dev/null +++ b/sys-fs/multipath-tools/Manifest @@ -0,0 +1 @@ +DIST multipath-tools-0.5.0.tar.bz2 184024 SHA256 f13cf1eb84e94e83b2019e68f7965526903c13e94246db43965d181668a0a6f9 SHA512 dfad21c45d0f69e39041d30d203a582c8ee8329bf390c51cde10155b3de379e7ad8fead2ac4beb268a924fd7e7dc8e1cf538ea3c70d41479fd8786fa30ba22a9 WHIRLPOOL bc8a365d66d1c5f584de04304125949926d4a1576cba4a00acca0f1333eb13d83318da36d9d88c5dc92691a331d427ad6b99eb1f2983fbc387303dbfdbae11ff diff --git a/sys-fs/multipath-tools/files/multipath-tools-0.5.0-makefile.patch b/sys-fs/multipath-tools/files/multipath-tools-0.5.0-makefile.patch new file mode 100644 index 000000000000..691b138731f6 --- /dev/null +++ b/sys-fs/multipath-tools/files/multipath-tools-0.5.0-makefile.patch @@ -0,0 +1,200 @@ +--- multipath-tools-0.5.0/kpartx/Makefile ++++ multipath-tools-0.5.0/kpartx/Makefile +@@ -12,7 +12,7 @@ + CFLAGS += -DLIBDM_API_COOKIE + endif + +-LDFLAGS = -ldevmapper ++LIBS = -ldevmapper + OBJS = bsd.o dos.o kpartx.o solaris.o unixware.o dasd.o sun.o \ + gpt.o mac.o ps3.o crc32.o lopart.o xstrncpy.o devmapper.o + EXEC = kpartx +@@ -20,8 +20,7 @@ + all: $(EXEC) + + $(EXEC): $(OBJS) +- $(CC) $(OBJS) -o $(EXEC) $(LDFLAGS) +- $(GZIP) $(EXEC).8 > $(EXEC).8.gz ++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC) + + install: $(EXEC) $(EXEC).8 + $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir) +@@ -29,14 +28,15 @@ + $(INSTALL_PROGRAM) -d $(DESTDIR)$(libudevdir) + $(INSTALL_PROGRAM) -m 755 kpartx_id $(DESTDIR)$(libudevdir) + $(INSTALL_PROGRAM) -d $(DESTDIR)/etc/udev/rules.d +- $(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)/etc/udev/rules.d/ ++ $(INSTALL_PROGRAM) -m 644 kpartx.rules $(DESTDIR)/etc/udev/rules.d/66-kpartx.rules + $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir) +- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir) ++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir) + + uninstall: + rm -f $(DESTDIR)$(bindir)/$(EXEC) +- rm -f $(DESTDIR)$(mandir)/$(EXEC).8.gz ++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8 + rm -f $(DESTDIR)$(libudevdir)/kpartx_id ++ rm -f $(DESTDIR)/etc/udev/rules.d/66-kpartx.rules + + clean: +- rm -f core *.o $(EXEC) *.gz ++ rm -f core *.o $(EXEC) +--- multipath-tools-0.5.0/libmpathpersist/Makefile ++++ multipath-tools-0.5.0/libmpathpersist/Makefile +@@ -22,8 +22,6 @@ + $(CC) -Wall -fPIC -c $(CFLAGS) *.c + $(CC) -shared $(LIBDEPS) -Wl,-soname=$@ $(CFLAGS) -o $@ $(OBJS) + ln -s $(LIBS) $(DEVLIB) +- $(GZIP) mpath_persistent_reserve_in.3 > mpath_persistent_reserve_in.3.gz +- $(GZIP) mpath_persistent_reserve_out.3 > mpath_persistent_reserve_out.3.gz + + install: $(LIBS) + $(INSTALL_PROGRAM) -d $(DESTDIR)$(syslibdir) +@@ -31,19 +29,17 @@ + $(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)$(syslibdir) + $(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)$(man3dir) + $(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)/usr/include/ +- $(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)/usr/share/doc/mpathpersist/ +- ln -sf $(DESTDIR)$(syslibdir)/$(LIBS) $(DESTDIR)$(syslibdir)/$(DEVLIB) +- install -m 644 mpath_persistent_reserve_in.3.gz $(DESTDIR)$(man3dir) +- install -m 644 mpath_persistent_reserve_out.3.gz $(DESTDIR)$(man3dir) +- install -m 644 mpath_persist.h $(DESTDIR)/usr/include/ ++ $(INSTALL_PROGRAM) -m 644 mpath_persistent_reserve_in.3 $(DESTDIR)$(man3dir) ++ $(INSTALL_PROGRAM) -m 644 mpath_persistent_reserve_out.3 $(DESTDIR)$(man3dir) ++ $(INSTALL_PROGRAM) -m 644 mpath_persist.h $(DESTDIR)/usr/include/ + + uninstall: + rm -f $(DESTDIR)$(syslibdir)/$(LIBS) +- rm $(DESTDIR)$(mandir)/mpath_persistent_reserve_in.3.gz +- rm $(DESTDIR)$(mandir)/mpath_persistent_reserve_out.3.gz ++ rm $(DESTDIR)$(mandir)/mpath_persistent_reserve_in.3 ++ rm $(DESTDIR)$(mandir)/mpath_persistent_reserve_out.3 + + clean: + rm -f core *.a *.o + rm -f libmpathpersist.so.0 + rm -f libmpathpersist.so +- rm -f mpath_persistent_reserve_in.3.gz mpath_persistent_reserve_out.3.gz ++ rm -f mpath_persistent_reserve_in.3 mpath_persistent_reserve_out.3 +--- multipath-tools-0.5.0/Makefile.inc ++++ multipath-tools-0.5.0/Makefile.inc +@@ -48,8 +48,8 @@ + RPM_OPT_FLAGS = -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 + endif + +-OPTFLAGS = $(RPM_OPT_FLAGS) -Wunused -Wstrict-prototypes +-CFLAGS = $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\" ++OPTFLAGS = -Wall -Wunused -Wstrict-prototypes ++CFLAGS += $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\" + SHARED_FLAGS = -shared + + %.o: %.c +--- multipath-tools-0.5.0/mpathpersist/Makefile ++++ multipath-tools-0.5.0/mpathpersist/Makefile +@@ -13,18 +13,17 @@ + + $(EXEC): $(OBJS) + $(CC) -g $(OBJS) -o $(EXEC) $(LDFLAGS) $(CFLAGS) +- $(GZIP) $(EXEC).8 > $(EXEC).8.gz + + install: + install -d $(DESTDIR)$(bindir) + install -m 755 $(EXEC) $(DESTDIR)$(bindir)/ + install -d $(DESTDIR)$(mandir) +- install -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir) ++ install -m 644 $(EXEC).8 $(DESTDIR)$(mandir) + + clean: + rm -f *.o $(EXEC) +- rm -f mpathpersist.8.gz ++ rm -f mpathpersist.8 + + uninstall: + rm $(DESTDIR)$(bindir)/$(EXEC) +- rm $(DESTDIR)$(mandir)/$(EXEC).8.gz ++ rm $(DESTDIR)$(mandir)/$(EXEC).8 +--- multipath-tools-0.5.0/multipath/Makefile ++++ multipath-tools-0.5.0/multipath/Makefile +@@ -7,29 +7,27 @@ + OBJS = main.o + + CFLAGS += -I$(multipathdir) +-LDFLAGS += -lpthread -ldevmapper -ldl -L$(multipathdir) -lmultipath -ludev ++LIBS += -lpthread -ldevmapper -ldl -L$(multipathdir) -lmultipath -ludev + + EXEC = multipath + + all: $(EXEC) + + $(EXEC): $(OBJS) +- $(CC) $(CFLAGS) $(OBJS) -o $(EXEC) $(LDFLAGS) +- $(GZIP) $(EXEC).8 > $(EXEC).8.gz +- $(GZIP) $(EXEC).conf.5 > $(EXEC).conf.5.gz ++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC) + + install: + $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir) + $(INSTALL_PROGRAM) -m 755 $(EXEC) $(DESTDIR)$(bindir)/ + $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir) +- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir) ++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir) + $(INSTALL_PROGRAM) -d $(DESTDIR)$(man5dir) +- $(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5.gz $(DESTDIR)$(man5dir) ++ $(INSTALL_PROGRAM) -m 644 $(EXEC).conf.5 $(DESTDIR)$(man5dir) + + uninstall: + rm $(DESTDIR)$(bindir)/$(EXEC) +- rm $(DESTDIR)$(mandir)/$(EXEC).8.gz +- rm $(DESTDIR)$(man5dir)/$(EXEC).conf.5.gz ++ rm $(DESTDIR)$(mandir)/$(EXEC).8 ++ rm $(DESTDIR)$(man5dir)/$(EXEC).conf.5 + + clean: +- rm -f core *.o $(EXEC) *.gz ++ rm -f core *.o $(EXEC) +--- multipath-tools-0.5.0/multipathd/Makefile ++++ multipath-tools-0.5.0/multipathd/Makefile +@@ -9,11 +9,11 @@ + ifdef SYSTEMD + CFLAGS += -DUSE_SYSTEMD=$(SYSTEMD) + endif +-LDFLAGS += -lpthread -ldevmapper -lreadline ++LIBS += -lpthread -ldevmapper -lreadline + ifdef SYSTEMD +- LDFLAGS += -lsystemd-daemon ++ LIBS += -lsystemd-daemon + endif +-LDFLAGS += -ludev -ldl \ ++LIBS += -ludev -ldl \ + -L$(multipathdir) -lmultipath -L$(mpathpersistdir) -lmpathpersist + + # +@@ -35,8 +35,7 @@ + all : $(EXEC) + + $(EXEC): $(OBJS) +- $(CC) $(CFLAGS) $(OBJS) $(LDFLAGS) -o $(EXEC) +- $(GZIP) $(EXEC).8 > $(EXEC).8.gz ++ $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(EXEC) + + install: + $(INSTALL_PROGRAM) -d $(DESTDIR)$(bindir) +@@ -48,15 +47,15 @@ + $(INSTALL_PROGRAM) -m 644 $(EXEC).socket $(DESTDIR)$(unitdir) + endif + $(INSTALL_PROGRAM) -d $(DESTDIR)$(mandir) +- $(INSTALL_PROGRAM) -m 644 $(EXEC).8.gz $(DESTDIR)$(mandir) ++ $(INSTALL_PROGRAM) -m 644 $(EXEC).8 $(DESTDIR)$(mandir) + + uninstall: + rm -f $(DESTDIR)$(bindir)/$(EXEC) + rm -f $(DESTDIR)$(rcdir)/$(EXEC) +- rm -f $(DESTDIR)$(mandir)/$(EXEC).8.gz ++ rm -f $(DESTDIR)$(mandir)/$(EXEC).8 + rm -f $(DESTDIR)$(unitdir)/$(EXEC).service + rm -f $(DESTDIR)$(unitdir)/$(EXEC).socket + + clean: +- rm -f core *.o $(EXEC) *.gz ++ rm -f core *.o $(EXEC) + diff --git a/sys-fs/multipath-tools/files/multipath-tools-0.5.0-systemd-pkgconfig.patch b/sys-fs/multipath-tools/files/multipath-tools-0.5.0-systemd-pkgconfig.patch new file mode 100644 index 000000000000..d75f841361a6 --- /dev/null +++ b/sys-fs/multipath-tools/files/multipath-tools-0.5.0-systemd-pkgconfig.patch @@ -0,0 +1,24 @@ +diff -ru multipath-tools-0.5.0/libmultipath/Makefile multipath-tools-0.5.0-modified/libmultipath/Makefile +--- multipath-tools-0.5.0/libmultipath/Makefile 2013-12-17 22:40:41.000000000 +0100 ++++ multipath-tools-0.5.0-modified/libmultipath/Makefile 2014-03-07 04:03:45.963309627 +0100 +@@ -9,7 +9,7 @@ + LIBS = $(DEVLIB).$(SONAME) + LIBDEPS = -lpthread -ldl -ldevmapper -ludev + ifdef SYSTEMD +- LIBDEPS += -lsystemd-daemon ++ LIBDEPS += $(shell pkg-config --libs libsystemd 2>/dev/null || pkg-config --libs libsystemd-daemon 2>/dev/null) + endif + + OBJS = memory.o parser.o vector.o devmapper.o callout.o \ +diff -ru multipath-tools-0.5.0/multipathd/Makefile multipath-tools-0.5.0-modified/multipathd/Makefile +--- multipath-tools-0.5.0/multipathd/Makefile 2014-03-07 04:05:09.340307633 +0100 ++++ multipath-tools-0.5.0-modified/multipathd/Makefile 2014-03-07 04:04:03.555309206 +0100 +@@ -11,7 +11,7 @@ + endif + LIBS += -lpthread -ldevmapper -lreadline + ifdef SYSTEMD +- LIBS += -lsystemd-daemon ++ LIBS += $(shell pkg-config --libs libsystemd 2>/dev/null || pkg-config --libs libsystemd-daemon 2>/dev/null) + endif + LIBS += -ludev -ldl \ + -L$(multipathdir) -lmultipath -L$(mpathpersistdir) -lmpathpersist diff --git a/sys-fs/multipath-tools/files/multipath.rc b/sys-fs/multipath-tools/files/multipath.rc new file mode 100755 index 000000000000..cf43e5b30710 --- /dev/null +++ b/sys-fs/multipath-tools/files/multipath.rc @@ -0,0 +1,27 @@ +#!/sbin/runscript +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +depend() { + before checkfs fsck multipathd lvm + after modules device-mapper +} + +start() { + if ! grep -qs device-mapper /proc/devices /proc/misc ; then + [ -e /proc/modules ] && modprobe -q dm-mod + fi + + ebegin "Activating Multipath devices" + multipath -v0 >/dev/null + eend $? +} + +stop() { + ebegin "Shutting down Multipath devices" + multipath -v0 -F >/dev/null + eend $? +} + +# vim:ts=4 diff --git a/sys-fs/multipath-tools/files/rc-multipathd b/sys-fs/multipath-tools/files/rc-multipathd new file mode 100644 index 000000000000..646a911d0de8 --- /dev/null +++ b/sys-fs/multipath-tools/files/rc-multipathd @@ -0,0 +1,21 @@ +#!/sbin/runscript +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +depend() { + need localmount + after modules +} + +start() { + ebegin "Starting multipathd" + start-stop-daemon --start --quiet --exec /sbin/multipathd + eend $? +} + +stop() { + ebegin "Stopping multipathd" + start-stop-daemon --stop --quiet --pidfile /var/run/multipathd.pid + eend $? +} diff --git a/sys-fs/multipath-tools/metadata.xml b/sys-fs/multipath-tools/metadata.xml new file mode 100644 index 000000000000..96a2d586367d --- /dev/null +++ b/sys-fs/multipath-tools/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>base-system</herd> +</pkgmetadata> diff --git a/sys-fs/multipath-tools/multipath-tools-0.5.0-r1.ebuild b/sys-fs/multipath-tools/multipath-tools-0.5.0-r1.ebuild new file mode 100644 index 000000000000..33644346fda8 --- /dev/null +++ b/sys-fs/multipath-tools/multipath-tools-0.5.0-r1.ebuild @@ -0,0 +1,66 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=4 +inherit eutils systemd toolchain-funcs udev + +DESCRIPTION="Device mapper target autoconfig" +HOMEPAGE="http://christophe.varoqui.free.fr/" +SRC_URI="http://christophe.varoqui.free.fr/${PN}/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 ~arm ~ia64 ppc ppc64 ~sparc x86" +IUSE="systemd" + +RDEPEND=">=sys-fs/lvm2-2.02.45 + >=virtual/udev-171 + dev-libs/libaio + sys-libs/readline + systemd? ( sys-apps/systemd )" +DEPEND="${RDEPEND} + virtual/pkgconfig" + +src_prepare() { + epatch "${FILESDIR}"/${P}-makefile.patch + epatch "${FILESDIR}"/${P}-systemd-pkgconfig.patch + epatch_user +} + +src_compile() { + # LIBDM_API_FLUSH involves grepping files in /usr/include, + # so force the test to go the way we want #411337. + emake LIBDM_API_FLUSH=1 CC="$(tc-getCC)" SYSTEMD=$(usex systemd 1 "") +} + +src_install() { + local udevdir="$(get_udevdir)" + + dodir /sbin /usr/share/man/man8 + emake \ + DESTDIR="${D}" \ + SYSTEMD=$(usex systemd 1 "") \ + unitdir="$(systemd_get_unitdir)" \ + libudevdir='${prefix}'/"${udevdir}" \ + install + + insinto /etc + newins "${S}"/multipath.conf.annotated multipath.conf + # /etc/udev is reserved for user modified rules! + mv "${D}"/etc/udev/rules.d "${D}/${udevdir}"/ || die + fperms 644 "${udevdir}"/rules.d/66-kpartx.rules + newinitd "${FILESDIR}"/rc-multipathd multipathd + newinitd "${FILESDIR}"/multipath.rc multipath + + dodoc multipath.conf.* AUTHOR ChangeLog FAQ + docinto kpartx + dodoc kpartx/ChangeLog kpartx/README +} + +pkg_postinst() { + if [[ -z ${REPLACING_VERSIONS} ]]; then + elog "If you need multipath on your system, you must" + elog "add 'multipath' into your boot runlevel!" + fi +} |