1 |
miska 12/02/25 22:56:56 |
2 |
|
3 |
Modified: ChangeLog obs-service.eclass |
4 |
Log: |
5 |
Improved obs-service eclass to fix paths to suse-build automatically |
6 |
|
7 |
Revision Changes Path |
8 |
1.143 eclass/ChangeLog |
9 |
|
10 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.143&view=markup |
11 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.143&content-type=text/plain |
12 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.142&r2=1.143 |
13 |
|
14 |
Index: ChangeLog |
15 |
=================================================================== |
16 |
RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v |
17 |
retrieving revision 1.142 |
18 |
retrieving revision 1.143 |
19 |
diff -u -r1.142 -r1.143 |
20 |
--- ChangeLog 25 Feb 2012 06:26:14 -0000 1.142 |
21 |
+++ ChangeLog 25 Feb 2012 22:56:56 -0000 1.143 |
22 |
@@ -1,6 +1,9 @@ |
23 |
# ChangeLog for eclass directory |
24 |
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 |
25 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.142 2012/02/25 06:26:14 robbat2 Exp $ |
26 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.143 2012/02/25 22:56:56 miska Exp $ |
27 |
+ |
28 |
+ 25 Feb 2012; Michal Hrusecky <miska@g.o> obs-service.eclass: |
29 |
+ Improved obs-service eclass to fix paths to suse-build automatically |
30 |
|
31 |
25 Feb 2012; Robin H. Johnson <robbat2@g.o> linux-mod.eclass: |
32 |
Bug #404193: Depend on virtual/modutils instead of |
33 |
|
34 |
|
35 |
|
36 |
1.2 eclass/obs-service.eclass |
37 |
|
38 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/obs-service.eclass?rev=1.2&view=markup |
39 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/obs-service.eclass?rev=1.2&content-type=text/plain |
40 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/obs-service.eclass?r1=1.1&r2=1.2 |
41 |
|
42 |
Index: obs-service.eclass |
43 |
=================================================================== |
44 |
RCS file: /var/cvsroot/gentoo-x86/eclass/obs-service.eclass,v |
45 |
retrieving revision 1.1 |
46 |
retrieving revision 1.2 |
47 |
diff -u -r1.1 -r1.2 |
48 |
--- obs-service.eclass 16 Sep 2011 15:49:19 -0000 1.1 |
49 |
+++ obs-service.eclass 25 Feb 2012 22:56:56 -0000 1.2 |
50 |
@@ -1,6 +1,6 @@ |
51 |
-# Copyright 1999-2011 Gentoo Foundation |
52 |
+# Copyright 1999-2012 Gentoo Foundation |
53 |
# Distributed under the terms of the GNU General Public License v2 |
54 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/obs-service.eclass,v 1.1 2011/09/16 15:49:19 miska Exp $ |
55 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/obs-service.eclass,v 1.2 2012/02/25 22:56:56 miska Exp $ |
56 |
|
57 |
# @ECLASS: obs-service.eclass |
58 |
# @MAINTAINER: |
59 |
@@ -65,13 +65,25 @@ |
60 |
SRC_URI+=" ${OBS_URI}/${i}" |
61 |
done |
62 |
|
63 |
-S="${WORKDIR}" |
64 |
- |
65 |
-# @FUNCTION: obs-service_src_configure |
66 |
+# @FUNCTION: obs-service_src_unpack |
67 |
# @DESCRIPTION: |
68 |
-# Does nothing. Files are not compressed. |
69 |
+# Just copy files. Files are not compressed. |
70 |
obs-service_src_unpack() { |
71 |
debug-print-function ${FUNCNAME} "$@" |
72 |
+ cd "${DISTDIR}" |
73 |
+ mkdir -p "${S}" |
74 |
+ cp ${A} "${S}" |
75 |
+} |
76 |
+ |
77 |
+# @FUNCTION: obs-service_src_prepare |
78 |
+# @DESCRIPTION: |
79 |
+# Replaces all /usr/lib/build directories with /usr/share/suse-build to reflect |
80 |
+# where suse-build is installed in Gentoo. |
81 |
+obs-service_src_prepare() { |
82 |
+ debug-print-function ${FUNCNAME} "$@" |
83 |
+ debug-print "Replacing all paths to find suse-build in Gentoo" |
84 |
+ find "${S}" -type f -exec \ |
85 |
+ sed -i 's|/usr/lib/build|/usr/share/suse-build|g' {} + |
86 |
} |
87 |
|
88 |
# @FUNCTION: obs-service_src_install |
89 |
@@ -81,17 +93,17 @@ |
90 |
debug-print-function ${FUNCNAME} "$@" |
91 |
debug-print "Installing service \"${OBS_SERVICE_NAME}\"" |
92 |
exeinto /usr/lib/obs/service |
93 |
- doexe "${DISTDIR}"/${OBS_SERVICE_NAME} |
94 |
+ doexe "${S}"/${OBS_SERVICE_NAME} |
95 |
insinto /usr/lib/obs/service |
96 |
- doins "${DISTDIR}"/${OBS_SERVICE_NAME}.service |
97 |
+ doins "${S}"/${OBS_SERVICE_NAME}.service |
98 |
if [[ -n ${ADDITIONAL_FILES} ]]; then |
99 |
debug-print "Installing following additional files:" |
100 |
debug-print " ${ADDITIONAL_FILES}" |
101 |
exeinto /usr/lib/obs/service/${OBS_SERVICE_NAME}.files |
102 |
for i in ${ADDITIONAL_FILES}; do |
103 |
- doexe "${DISTDIR}"/${i} |
104 |
+ doexe "${S}"/${i} |
105 |
done |
106 |
fi |
107 |
} |
108 |
|
109 |
-EXPORT_FUNCTIONS src_install src_unpack |
110 |
+EXPORT_FUNCTIONS src_install src_prepare src_unpack |