1 |
commit: 11629c2e66238b3bf753201af27c3147e3ab5cc9 |
2 |
Author: Andreas K. Hüttel <dilfridge <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Jan 19 21:48:28 2022 +0000 |
4 |
Commit: Andreas K. Hüttel <dilfridge <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Jan 19 21:48:49 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=11629c2e |
7 |
|
8 |
app-backup/tsm: Version (and EAPI) bump |
9 |
|
10 |
Bug: https://bugs.gentoo.org/829189 |
11 |
Bug: https://bugs.gentoo.org/788115 |
12 |
Bug: https://bugs.gentoo.org/831509 |
13 |
Package-Manager: Portage-3.0.30, Repoman-3.0.3 |
14 |
Signed-off-by: Andreas K. Hüttel <dilfridge <AT> gentoo.org> |
15 |
|
16 |
app-backup/tsm/Manifest | 1 + |
17 |
app-backup/tsm/tsm-8.1.13.3.ebuild | 244 +++++++++++++++++++++++++++++++++++++ |
18 |
2 files changed, 245 insertions(+) |
19 |
|
20 |
diff --git a/app-backup/tsm/Manifest b/app-backup/tsm/Manifest |
21 |
index b1fe5ffa9f8a..0e8aad5c48f5 100644 |
22 |
--- a/app-backup/tsm/Manifest |
23 |
+++ b/app-backup/tsm/Manifest |
24 |
@@ -1 +1,2 @@ |
25 |
+DIST 8.1.13.3-TIV-TSMBAC-LinuxX86.tar 593264640 BLAKE2B 0dec77e87403f86aaf98b3dbc61c4dcf7a107d2dbdb1733ad97294669b122a202034928b6c83df931877c6cd08272f7920250fbd6262ec9f565afdc06dd42c2b SHA512 dac6b7f701e7fb8af49988da8df952c93879b57ea57daa88d4fff3c531423c73b24e89995894c041601faf1c33f115e5153461e2672254d9f29b65dd30c8ab8e |
26 |
DIST 8.1.6.0-TIV-TSMBAC-LinuxX86.tar 215961600 BLAKE2B de7e3083a87e72763ffee5adbabc20f546edbc771a9ea0017af591b677cb55832c366ec42da6258ccbb81368f7934acfd116eee77236737d8015cc7588d95d3e SHA512 82897f8af6e1408b25eb95206500fa2e05f17983843de3a3456d71ee3cc25188e31a0a2b11c7ee5cf02c3a6aa46fbba03e2a31e697868905739e97c75bfd5984 |
27 |
|
28 |
diff --git a/app-backup/tsm/tsm-8.1.13.3.ebuild b/app-backup/tsm/tsm-8.1.13.3.ebuild |
29 |
new file mode 100644 |
30 |
index 000000000000..91fe5ce9c71a |
31 |
--- /dev/null |
32 |
+++ b/app-backup/tsm/tsm-8.1.13.3.ebuild |
33 |
@@ -0,0 +1,244 @@ |
34 |
+# Copyright 1999-2022 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=8 |
38 |
+ |
39 |
+inherit readme.gentoo-r1 rpm systemd pax-utils |
40 |
+ |
41 |
+DESCRIPTION="IBM Spectrum Protect (former Tivoli Storage Manager) Backup/Archive Client, API" |
42 |
+HOMEPAGE="https://www.ibm.com/us-en/marketplace/data-protection-and-recovery" |
43 |
+ |
44 |
+MY_PV_MAJOR=$(ver_cut 1) |
45 |
+MY_PV_MINOR=$(ver_cut 2) |
46 |
+MY_PV_TINY=$(ver_cut 3) |
47 |
+MY_PV_PATCH=$(ver_cut 4) |
48 |
+ |
49 |
+MY_PV_NODOTS="${MY_PV_MAJOR}${MY_PV_MINOR}${MY_PV_TINY}" |
50 |
+MY_PVR_ALLDOTS=${PV} |
51 |
+ |
52 |
+if [[ ${MY_PV_PATCH} == 0 ]]; then |
53 |
+ MY_RELEASE_PATH=maintenance |
54 |
+else |
55 |
+ MY_RELEASE_PATH=patches |
56 |
+fi |
57 |
+BASE_URI="ftp://ftp.software.ibm.com/storage/tivoli-storage-management/" |
58 |
+BASE_URI+="${MY_RELEASE_PATH}/client/v${MY_PV_MAJOR}r${MY_PV_MINOR}/" |
59 |
+BASE_URI+="Linux/LinuxX86/BA/v${MY_PV_NODOTS}/" |
60 |
+SRC_TAR="${MY_PVR_ALLDOTS}-TIV-TSMBAC-LinuxX86.tar" |
61 |
+SRC_URI="${BASE_URI}${SRC_TAR}" |
62 |
+ |
63 |
+RESTRICT="strip" # Breaks libPiIMG.so and libPiSNAP.so |
64 |
+LICENSE="Apache-1.1 Apache-2.0 JDOM BSD-2 CC-PD Boost-1.0 MIT CPL-1.0 HPND Exolab |
65 |
+ dom4j EPL-1.0 FTL icu unicode IBM Info-ZIP LGPL-2 LGPL-2.1 openafs-krb5-a |
66 |
+ ZLIB MPL-1.0 MPL-1.1 NPL-1.1 openssl OPENLDAP RSA public-domain W3C |
67 |
+ || ( BSD GPL-2+ ) gSOAP libpng tsm" |
68 |
+ |
69 |
+SLOT="0" |
70 |
+KEYWORDS="-* ~amd64" |
71 |
+IUSE="acl java +tsm-cit +tsm-hw" |
72 |
+QA_PREBUILT="*" |
73 |
+ |
74 |
+# not available (yet?) |
75 |
+#MY_LANGS="cs:CS_CZ de:DE_DE es:ES_ES fr:FR_FR hu:HU_HU it:IT_IT ja:JA_JP |
76 |
+# ko:KO_KR pl:PL_PL pt-BR:PT_BR ru:RU_RU zh-CN:ZH_CN zh-TW:ZH_TW" |
77 |
+MY_LANG_PV="${MY_PVR_ALLDOTS}-" |
78 |
+for lang in ${MY_LANGS}; do |
79 |
+ IUSE="${IUSE} l10n_${lang%:*}" |
80 |
+ SRC_URI="${SRC_URI} l10n_${lang%:*}? ( \ |
81 |
+${BASE_URI}TIVsm-msg.${lang#*:}.x86_64.rpm -> \ |
82 |
+${MY_LANG_PV}TIVsm-msg.${lang#*:}.x86_64.rpm )" |
83 |
+done |
84 |
+unset lang |
85 |
+ |
86 |
+DEPEND=" |
87 |
+ acct-group/tsm |
88 |
+" |
89 |
+RDEPEND=" |
90 |
+ acct-group/tsm |
91 |
+ dev-libs/expat |
92 |
+ dev-libs/libxml2 |
93 |
+ sys-fs/fuse:0 |
94 |
+ acl? ( sys-apps/acl ) |
95 |
+ java? ( >=virtual/jre-1.7 ) |
96 |
+ || ( |
97 |
+ sys-libs/libxcrypt[compat] |
98 |
+ sys-libs/glibc[crypt(+)] |
99 |
+ )" |
100 |
+ |
101 |
+S="${WORKDIR}/bacli" |
102 |
+ |
103 |
+pkg_setup() { |
104 |
+ DOC_CONTENTS=" |
105 |
+ Note that you have to be root to be able to use the Tivoli Storage Manager |
106 |
+ client. The dsmtca trusted agent binary does not exist anymore. |
107 |
+ |
108 |
+ For information on how to give other users access, please see the following |
109 |
+ URLs: |
110 |
+ https://www.ibm.com/support/knowledgecenter/SSGSG7_7.1.8/client/c_cfg_nonadmin.html#c_macuninst_nonadmin |
111 |
+ https://www.ibm.com/support/knowledgecenter/SSGSG7_7.1.8/client/c_secure_pwd.html#c_secure_pwd__sec_no_tca |
112 |
+ " |
113 |
+} |
114 |
+ |
115 |
+src_unpack() { |
116 |
+ local rpm rpms lang |
117 |
+ mkdir bacli || die |
118 |
+ cd bacli || die |
119 |
+ unpack ${SRC_TAR} |
120 |
+ |
121 |
+ cd "${S}" |
122 |
+ for rpm in *.rpm; do |
123 |
+ case ${rpm} in |
124 |
+ TIVsm-APIcit.*|TIVsm-BAcit.*) |
125 |
+ use tsm-cit && rpms="${rpms} ./${rpm}" |
126 |
+ ;; |
127 |
+ TIVsm-BAhdw.*) |
128 |
+ use tsm-hw && rpms="${rpms} ./${rpm}" |
129 |
+ ;; |
130 |
+ TIVsm-JBB.*|*-filepath-*) |
131 |
+ # "journal based backup" for all filesystems |
132 |
+ # requires a kernel module. |
133 |
+ # "Linux Filepath source code" available |
134 |
+ # by request from vendor |
135 |
+ ;; |
136 |
+ *) |
137 |
+ rpms="${rpms} ./${rpm}" |
138 |
+ ;; |
139 |
+ esac |
140 |
+ done |
141 |
+ for rpm in ${A}; do |
142 |
+ case ${rpm} in |
143 |
+ *.rpm) |
144 |
+ rpms="${rpms} ${rpm}" |
145 |
+ ;; |
146 |
+ esac |
147 |
+ done |
148 |
+ |
149 |
+ rpm_unpack ${rpms} |
150 |
+ |
151 |
+ # Avoid strange error messages caused by read-only files |
152 |
+ chmod -R u+w "${S}" || die |
153 |
+} |
154 |
+ |
155 |
+src_install() { |
156 |
+ cp -a opt "${D}"/ || die |
157 |
+ cp -a usr "${D}"/ || die |
158 |
+ |
159 |
+ # The RPM files contain postinstall scripts which can be extracted |
160 |
+ # e.g. using https://bugs.gentoo.org/attachment.cgi?id=234663 . |
161 |
+ # Below we try to mimic the behaviour of these scripts. |
162 |
+ # We don't deal with SELinux compliance (yet), though. |
163 |
+ local RPM_INSTALL_PREFIX CLIENTDIR i |
164 |
+ RPM_INSTALL_PREFIX=/opt |
165 |
+ CLIENTDIR=${RPM_INSTALL_PREFIX}/tivoli/tsm/client |
166 |
+ |
167 |
+ # Create links for messages; this is spread over several postin scripts. |
168 |
+ #for i in $(cd "${D}"/${CLIENTDIR}/lang; ls -1d ??_??); do |
169 |
+ # dosym ../../lang/${i} $CLIENTDIR/ba/bin/${i} |
170 |
+ # dosym ../../lang/${i} $CLIENTDIR/api/bin64/${i} |
171 |
+ #done |
172 |
+ |
173 |
+ # Mimic TIVsm-API64 postinstall script |
174 |
+ for i in libgpfs.so libdmapi.so; do |
175 |
+ dosym ../..${CLIENTDIR}/api/bin64/${i} /usr/lib64/${i} |
176 |
+ done |
177 |
+ |
178 |
+ # The TIVsm-BA postinstall script only does messages and ancient upgrades |
179 |
+ |
180 |
+ # The gscrypt64 postinstall script only deals with s390[x] SELinux |
181 |
+ # and the symlink for the iccs library which we handle in the loop below. |
182 |
+ |
183 |
+ # Move stuff from /usr/local to /opt, #452332 |
184 |
+ mv "${D}"/usr/local/ibm "${D}"/opt/ || die |
185 |
+ rmdir "${D}"/usr/local || die |
186 |
+ |
187 |
+ # Mimic gskssl64 postinstall script |
188 |
+ for i in sys p11 km ssl drld kicc ldap cms acmeidup valn dbfl iccs; do |
189 |
+ dosym ../../opt/ibm/gsk8_64/lib64/libgsk8${i}_64.so \ |
190 |
+ /usr/lib64/libgsk8${i}_64.so |
191 |
+ done |
192 |
+ for i in capicmd ver; do |
193 |
+ dosym ../../opt/ibm/gsk8_64/bin/gsk8${i}_64 /usr/bin/gsk${i}_64 |
194 |
+ done |
195 |
+ |
196 |
+ # Done with the postinstall scripts as the RPMs contain them. |
197 |
+ # Now on to some more Gentoo-specific installation. |
198 |
+ |
199 |
+ rm -rf "${D}/usr/lib/.build-id" &> /dev/null |
200 |
+ [[ -d "${D}/usr/lib" ]] && rmdir "${D}/usr/lib" || die "Using 32bit lib dir in 64bit only system" |
201 |
+ |
202 |
+ # Avoid "QA Notice: Found an absolute symlink in a library directory" |
203 |
+ local target |
204 |
+ find "${D}"/usr/lib* -lname '/*' | while read i; do |
205 |
+ target=$(readlink "${i}") |
206 |
+ rm -v "${i}" || die |
207 |
+ dosym "../..${target}" "${i#${D}/}" |
208 |
+ done |
209 |
+ |
210 |
+ keepdir /var/log/tsm |
211 |
+ insinto /etc/logrotate.d |
212 |
+ newins "${FILESDIR}/tsm.logrotate" tsm |
213 |
+ |
214 |
+ keepdir /etc/tivoli |
215 |
+ |
216 |
+ cp -a "${S}/opt/tivoli/tsm/client/ba/bin/dsm.sys.smp" "${D}/etc/tivoli/dsm.sys" || die |
217 |
+ echo ' PasswordDir "/etc/tivoli/"' >> ${D}/etc/tivoli/dsm.sys |
218 |
+ echo ' PasswordAccess generate' >> ${D}/etc/tivoli/dsm.sys |
219 |
+ |
220 |
+ # Added the hostname to be more friendly, the admin will need to edit this file anyway |
221 |
+ echo ' NodeName' `hostname` >> ${D}/etc/tivoli/dsm.sys |
222 |
+ echo ' ErrorLogName "/var/log/tsm/dsmerror.log"' >> ${D}/etc/tivoli/dsm.sys |
223 |
+ echo ' SchedLogName "/var/log/tsm/dsmsched.log"' >> ${D}/etc/tivoli/dsm.sys |
224 |
+ dosym ../../../../../../etc/tivoli/dsm.sys /opt/tivoli/tsm/client/ba/bin/dsm.sys |
225 |
+ |
226 |
+ cp -a "${S}/opt/tivoli/tsm/client/ba/bin/dsm.opt.smp" "${D}/etc/tivoli/dsm.opt" |
227 |
+ dosym ../../../../../../etc/tivoli/dsm.opt /opt/tivoli/tsm/client/ba/bin/dsm.opt |
228 |
+ |
229 |
+ # Setup the env |
230 |
+ dodir /etc/env.d |
231 |
+ ENV_FILE="${D}/etc/env.d/80tivoli" |
232 |
+ echo 'DSM_CONFIG="/etc/tivoli/dsm.opt"' >> ${ENV_FILE} |
233 |
+ echo 'DSM_DIR="/opt/tivoli/tsm/client/ba/bin"' >> ${ENV_FILE} |
234 |
+ echo 'DSM_LOG="/var/log/tsm"' >> ${ENV_FILE} |
235 |
+ # echo 'ROOTPATH="/opt/tivoli/tsm/client/ba/bin"' >> ${ENV_FILE} |
236 |
+ |
237 |
+ echo 'SEARCH_DIRS_MASK="/opt/tivoli/tsm/client/ba/bin"' > "${T}/80${PN}" || die |
238 |
+ insinto "/etc/revdep-rebuild" |
239 |
+ doins "${T}/80${PN}" |
240 |
+ |
241 |
+ newconfd "${FILESDIR}/dsmc.conf.d" dsmc |
242 |
+ newinitd "${FILESDIR}/dsmc.init.d" dsmc |
243 |
+ newinitd "${FILESDIR}/dsmcad.init.d-r1" dsmcad |
244 |
+ |
245 |
+ # Need this for hardened, otherwise a cryptic "connection to server lost" message appears |
246 |
+ pax-mark -m "${D}/opt/tivoli/tsm/client/ba/bin/dsmc" |
247 |
+ |
248 |
+ systemd_dounit "${FILESDIR}/dsmc.service" |
249 |
+ systemd_dounit "${FILESDIR}/dsmcad.service" |
250 |
+ |
251 |
+ readme.gentoo_create_doc |
252 |
+} |
253 |
+ |
254 |
+pkg_postinst() { |
255 |
+ local i dirs |
256 |
+ for i in /var/log/tsm/dsm{error,sched,j,webcl}.log; do |
257 |
+ if [[ ! -e ${i} ]]; then |
258 |
+ touch ${i} || die |
259 |
+ chown :tsm ${i} || die |
260 |
+ chmod 0660 ${i} || die |
261 |
+ fi |
262 |
+ done |
263 |
+ |
264 |
+ # Bug #375041: the log directory itself should not be world writable. |
265 |
+ # Have to do this in postinst due to bug #141619 |
266 |
+ chown root:tsm /var/log/tsm || die |
267 |
+ chmod 0750 /var/log/tsm || die |
268 |
+ |
269 |
+ # Bug 508052: directories used to be too restrictive, have to widen perms. |
270 |
+ dirs=( /opt/tivoli $(find /opt/tivoli/tsm -type d) ) |
271 |
+ chown root:root "${dirs[@]}" || die |
272 |
+ chmod 0755 "${dirs[@]}" || die |
273 |
+ |
274 |
+ FORCE_PRINT_ELOG=1 |
275 |
+ DISABLE_AUTOFORMATTING=1 |
276 |
+ readme.gentoo_print_elog |
277 |
+} |