Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 453594 | Differences between
and this patch

Collapse All | Expand All

(-)/usr/portage/sys-fs/lvm2/lvm2-2.02.98.ebuild (-44 / +40 lines)
Lines 3-9 Link Here
3
# $Header: /var/cvsroot/gentoo-x86/sys-fs/lvm2/lvm2-2.02.98.ebuild,v 1.4 2013/05/23 14:14:42 axs Exp $
3
# $Header: /var/cvsroot/gentoo-x86/sys-fs/lvm2/lvm2-2.02.98.ebuild,v 1.4 2013/05/23 14:14:42 axs Exp $
4
4
5
EAPI=5
5
EAPI=5
6
inherit eutils multilib toolchain-funcs autotools linux-info udev
6
inherit eutils multilib toolchain-funcs autotools linux-info systemd udev
7
7
8
DESCRIPTION="User-land utilities for LVM2 (device-mapper) software."
8
DESCRIPTION="User-land utilities for LVM2 (device-mapper) software."
9
HOMEPAGE="http://sources.redhat.com/lvm2/"
9
HOMEPAGE="http://sources.redhat.com/lvm2/"
Lines 47-52 Link Here
47
	local CONFIG_CHECK="~SYSVIPC"
47
	local CONFIG_CHECK="~SYSVIPC"
48
	use udev && local WARNING_SYSVIPC="CONFIG_SYSVIPC:\tis not set (required for udev sync)\n"
48
	use udev && local WARNING_SYSVIPC="CONFIG_SYSVIPC:\tis not set (required for udev sync)\n"
49
	check_extra_config
49
	check_extra_config
50
	if use udev && linux_config_exists; then
51
		local uevent_helper_path=$(linux_chkconfig_string UEVENT_HELPER_PATH)
52
		if [ -n "${uevent_helper_path}" ] && [ "${uevent_helper_path}" != '""' ]; then
53
			ewarn "It's highly recommended to set an empty value"
54
			ewarn "to the following kernel config option:"
55
			ewarn "CONFIG_UEVENT_HELPER_PATH=${uevent_helper_path}"
56
		fi
57
	fi
50
	# 1. Genkernel no longer copies /sbin/lvm blindly.
58
	# 1. Genkernel no longer copies /sbin/lvm blindly.
51
	if use static; then
59
	if use static; then
52
		elog "Warning, we no longer overwrite /sbin/lvm and /sbin/dmsetup with"
60
		elog "Warning, we no longer overwrite /sbin/lvm and /sbin/dmsetup with"
Lines 57-81 Link Here
57
65
58
src_prepare() {
66
src_prepare() {
59
	epatch "${FILESDIR}"/lvm.conf-2.02.67.patch
67
	epatch "${FILESDIR}"/lvm.conf-2.02.67.patch
60
61
	# Should not be needed due to upstream re-arrangement of build
62
	#epatch "${FILESDIR}"/${PN}-2.02.56-dmeventd.patch
63
	# Should not be need with new upstream udev rules
64
	#epatch "${FILESDIR}"/${PN}-2.02.56-device-mapper-export-format.patch
65
66
	# Merged upstream:
67
	#epatch "${FILESDIR}"/${PN}-2.02.51-as-needed.patch
68
	# Merged upstream:
69
	#epatch "${FILESDIR}"/${PN}-2.02.48-fix-pkgconfig.patch
70
	# Merged upstream:
71
	#epatch "${FILESDIR}"/${PN}-2.02.51-fix-pvcreate.patch
72
	# Fixed differently upstream:
73
	#epatch "${FILESDIR}"/${PN}-2.02.51-dmsetup-selinux-linking-fix-r3.patch
74
75
	epatch "${FILESDIR}"/${PN}-2.02.63-always-make-static-libdm.patch
68
	epatch "${FILESDIR}"/${PN}-2.02.63-always-make-static-libdm.patch
76
	epatch "${FILESDIR}"/lvm2-2.02.56-lvm2create_initrd.patch
69
	epatch "${FILESDIR}"/${PN}-2.02.56-lvm2create_initrd.patch
77
	# bug 318513 - merged upstream
70
78
	#epatch "${FILESDIR}"/${PN}-2.02.64-dmeventd-libs.patch
79
	# bug 301331
71
	# bug 301331
80
	epatch "${FILESDIR}"/${PN}-2.02.67-createinitrd.patch
72
	epatch "${FILESDIR}"/${PN}-2.02.67-createinitrd.patch
81
	# bug 330373
73
	# bug 330373
Lines 84-115 Link Here
84
	epatch "${FILESDIR}"/${PN}-2.02.70-asneeded.patch
76
	epatch "${FILESDIR}"/${PN}-2.02.70-asneeded.patch
85
	# bug 332905
77
	# bug 332905
86
	epatch "${FILESDIR}"/${PN}-2.02.92-dynamic-static-ldflags.patch
78
	epatch "${FILESDIR}"/${PN}-2.02.92-dynamic-static-ldflags.patch
87
	# bug 361429 - merged upstream in .85
88
	#epatch "${FILESDIR}"/${PN}-2.02.84-udev-pkgconfig.patch
89
90
	# Merged upstream
91
	#epatch "${FILESDIR}"/${PN}-2.02.73-asneeded.patch
92
79
93
	epatch "${FILESDIR}"/${PN}-2.02.88-respect-cc.patch
80
	epatch "${FILESDIR}"/${PN}-2.02.88-respect-cc.patch
94
81
95
	# Upstream bug of LVM path
96
	# Merged upstream
97
	#epatch "${FILESDIR}"/${PN}-2.02.95-lvmpath.patch
98
99
	# Upstream patch for http://bugs.gentoo.org/424810
100
	# Merged upstream
101
	#epatch "${FILESDIR}"/${PN}-2.02.95-udev185.patch
102
103
	# Upstream patch for https://bugs.gentoo.org/444328
104
	# Merged upstream
105
	#epatch "${FILESDIR}"/${PN}-2.02.97-strict-aliasing.patch
106
107
	# Fix calling AR directly with USE static, bug #444082
82
	# Fix calling AR directly with USE static, bug #444082
108
	if use static ; then
83
	if use static ; then
109
		sed -i -e "s:\$(AR) rs \$@ \$(OBJECTS) lvmcmdlib.o lvm2cmd-static.o:$(tc-getAR) rs \$@ \$(OBJECTS) lvmcmdlib.o lvm2cmd-static.o:" \
84
		sed -i -e "s:\$(AR) rs \$@ \$(OBJECTS) lvmcmdlib.o lvm2cmd-static.o:$(tc-getAR) rs \$@ \$(OBJECTS) lvmcmdlib.o lvm2cmd-static.o:" \
110
			tools/Makefile.in || die "sed failed"
85
			tools/Makefile.in || die "sed failed"
111
	fi
86
	fi
112
87
88
	# gentoo has lvm installed in /sbin
89
	sed -i 's:/usr/sbin/lvm:/sbin/lvm:' \
90
	scripts/lvm2_activation_generator_systemd_red_hat.c || die "sed failed"
91
113
	eautoreconf
92
	eautoreconf
114
}
93
}
115
94
Lines 117-128 Link Here
117
	local myconf
96
	local myconf
118
	local buildmode
97
	local buildmode
119
98
120
	myconf="${myconf} --enable-dmeventd"
121
	myconf="${myconf} --enable-cmdlib"
122
	myconf="${myconf} --enable-applib"
123
	myconf="${myconf} --enable-fsadm"
124
	myconf="${myconf} --enable-lvmetad"
125
126
	# Most of this package does weird stuff.
99
	# Most of this package does weird stuff.
127
	# The build options are tristate, and --without is NOT supported
100
	# The build options are tristate, and --without is NOT supported
128
	# options: 'none', 'internal', 'shared'
101
	# options: 'none', 'internal', 'shared'
Lines 181-197 Link Here
181
	use udev && udevdir="${EPREFIX}/$(udev_get_udevdir)/rules.d"
154
	use udev && udevdir="${EPREFIX}/$(udev_get_udevdir)/rules.d"
182
155
183
	econf \
156
	econf \
184
		$(use_enable readline) \
157
		--enable-dmeventd \
185
		$(use_enable selinux) \
158
		--enable-cmdlib \
159
		--enable-applib \
160
		--enable-fsadm \
161
		--enable-lvmetad \
186
		--enable-pkgconfig \
162
		--enable-pkgconfig \
187
		--with-confdir="${EPREFIX}/etc" \
163
		--with-confdir="${EPREFIX}/etc" \
188
		--sbindir="${EPREFIX}/sbin" \
164
		--sbindir="${EPREFIX}/sbin" \
189
		--with-staticdir="${EPREFIX}/sbin" \
165
		--with-staticdir="${EPREFIX}/sbin" \
190
		--libdir="${EPREFIX}/$(get_libdir)" \
166
		--libdir="${EPREFIX}/$(get_libdir)" \
191
		--with-usrlibdir="${EPREFIX}/usr/$(get_libdir)" \
167
		--with-usrlibdir="${EPREFIX}/usr/$(get_libdir)" \
168
		--with-default-dm-run-dir=/run \
192
		--with-default-run-dir=/run/lvm \
169
		--with-default-run-dir=/run/lvm \
170
		--with-default-pid-dir=/run \
193
		--with-default-locking-dir=/run/lock/lvm \
171
		--with-default-locking-dir=/run/lock/lvm \
194
		--with-dmeventd-path=/sbin/dmeventd \
172
		--with-dmeventd-path=/sbin/dmeventd \
173
		$(systemd_with_unitdir) \
174
		$(use_enable readline) \
175
		$(use_enable selinux) \
195
		$(use_enable udev udev_rules) \
176
		$(use_enable udev udev_rules) \
196
		$(use_enable udev udev_sync) \
177
		$(use_enable udev udev_sync) \
197
		$(use_with udev udevdir "${udevdir}") \
178
		$(use_with udev udevdir "${udevdir}") \
Lines 207-217 Link Here
207
188
208
	einfo "Starting main build"
189
	einfo "Starting main build"
209
	emake AR="$(tc-getAR)" || die "compile fail"
190
	emake AR="$(tc-getAR)" || die "compile fail"
191
192
	# when using systemd with lvmetad disabled
193
	# a generator is needed for systemd to create /dev nodes
194
	# note: this should be already build, but I am not sure
195
	# if this is always, or just sometimes, better to force
196
	emake -C scripts lvm2_activation_generator_systemd_red_hat
210
}
197
}
211
198
212
src_install() {
199
src_install() {
213
	emake DESTDIR="${D}" install
200
	emake DESTDIR="${D}" install
214
201
202
	# install systemd files
203
	emake DESTDIR="${D}" install_systemd_generators
204
	emake DESTDIR="${D}" install_systemd_units
205
	emake DESTDIR="${D}" install_tmpfiles_configuration
206
215
	dodoc README VERSION* WHATS_NEW WHATS_NEW_DM doc/*.{conf,c,txt}
207
	dodoc README VERSION* WHATS_NEW WHATS_NEW_DM doc/*.{conf,c,txt}
216
	newinitd "${FILESDIR}"/lvm.rc-2.02.95-r2 lvm
208
	newinitd "${FILESDIR}"/lvm.rc-2.02.95-r2 lvm
217
	newinitd "${FILESDIR}"/lvm-monitoring.initd-2.02.67-r2 lvm-monitoring
209
	newinitd "${FILESDIR}"/lvm-monitoring.initd-2.02.67-r2 lvm-monitoring
Lines 270-275 Link Here
270
	elog "baselayout-2 users. If you are using baselayout-2, be sure to"
262
	elog "baselayout-2 users. If you are using baselayout-2, be sure to"
271
	elog "run: # rc-update add lvm boot"
263
	elog "run: # rc-update add lvm boot"
272
	elog "Do NOT add it if you are still using baselayout-1."
264
	elog "Do NOT add it if you are still using baselayout-1."
265
266
	ewarn "Be sure to enabled use_lvmetad in /etc/lvm/lvm.conf"
267
	ewarn "if you want to enable lvm autoactivation and metadata caching"
268
	ewarn "More info can be found in lvmetad and lvm.conf man pages"
273
}
269
}
274
270
275
src_test() {
271
src_test() {

Return to bug 453594