From b63c3b13ef310101338a446e92b94e0fb7a17a06b883f8da48f7a5cfd9793f5f Mon Sep 17 00:00:00 2001 From: David Disseldorp Date: Mon, 8 Sep 2014 09:25:04 +0000 Subject: [PATCH] - Remove mkinitrd files and spec file logic. Dracut offers cifs support via the corresponding module; (bnc#893575). OBS-URL: https://build.opensuse.org/package/show/network:samba:STABLE/cifs-utils?expand=0&rev=112 --- cifs-utils.changes | 6 ++++ cifs-utils.spec | 23 +--------------- mkinitrd_scripts_boot-cifs.sh | 50 ---------------------------------- mkinitrd_scripts_setup-cifs.sh | 9 ------ 4 files changed, 7 insertions(+), 81 deletions(-) delete mode 100644 mkinitrd_scripts_boot-cifs.sh delete mode 100644 mkinitrd_scripts_setup-cifs.sh diff --git a/cifs-utils.changes b/cifs-utils.changes index 888ecf0..b167879 100644 --- a/cifs-utils.changes +++ b/cifs-utils.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sun Aug 31 19:15:08 UTC 2014 - ddiss@suse.com + +- Remove mkinitrd files and spec file logic. Dracut offers cifs support via + the corresponding module; (bnc#893575). + ------------------------------------------------------------------- Tue Aug 19 15:24:31 UTC 2014 - lmuelle@suse.com diff --git a/cifs-utils.spec b/cifs-utils.spec index 977da43..a11650c 100644 --- a/cifs-utils.spec +++ b/cifs-utils.spec @@ -32,10 +32,8 @@ Source6: ftp://ftp.samba.org/pub/linux-cifs/cifs-utils/cifs-utils-pubkey_ %define NET_CFGDIR network-scripts %endif Source1: cifs.init -Source2: mkinitrd_scripts_boot-cifs.sh -Source3: mkinitrd_scripts_setup-cifs.sh %if 0%{?suse_version} -PreReq: insserv %{?fillup_prereq} mkinitrd +PreReq: insserv %{?fillup_prereq} %else PreReq: /sbin/chkconfig %endif @@ -136,11 +134,6 @@ ln -s %{_libdir}/%{name}/idmapwb.so %{buildroot}%{_sysconfdir}/%{name}/idmap-plu mkdir -p %{buildroot}%{_sysconfdir}/request-key.d install -m 644 -p contrib/request-key.d/cifs.idmap.conf %{buildroot}%{_sysconfdir}/request-key.d install -m 644 -p contrib/request-key.d/cifs.spnego.conf %{buildroot}%{_sysconfdir}/request-key.d -%if 0%{?suse_version} > 1100 - mkdir -p ${RPM_BUILD_ROOT}/lib/mkinitrd/scripts/ - %{__install} -m 0755 ${RPM_SOURCE_DIR}/mkinitrd_scripts_boot-cifs.sh ${RPM_BUILD_ROOT}/lib/mkinitrd/scripts/boot-cifs.sh - %{__install} -m 0755 ${RPM_SOURCE_DIR}/mkinitrd_scripts_setup-cifs.sh ${RPM_BUILD_ROOT}/lib/mkinitrd/scripts/setup-cifs.sh -%endif %if 0%{?suse_version} == 0 || 0%{?suse_version} > 1221 mkdir -p \ ${RPM_BUILD_ROOT}/%{_sysconfdir}/sysconfig/%{NET_CFGDIR}/if-{down,up}.d \ @@ -157,14 +150,6 @@ touch ${RPM_BUILD_ROOT}/%{_sysconfdir}/sysconfig/%{NET_CFGDIR}/if-{down,up}.d/${ %fdupes ${RPM_BUILD_ROOT} %endif -%post -[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup -exit 0 - -%postun -[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup -exit 0 - %files %defattr(-,root,root) /sbin/mount.cifs @@ -184,12 +169,6 @@ exit 0 %endif %doc %{_mandir}/man8/mount.cifs.8.* %dir %{_sysconfdir}/request-key.d -%if 0%{?suse_version} > 1100 -%dir /lib/mkinitrd -%dir /lib/mkinitrd/scripts -/lib/mkinitrd/scripts/setup-cifs.sh -/lib/mkinitrd/scripts/boot-cifs.sh -%endif %config(noreplace) %{_sysconfdir}/request-key.d/cifs.idmap.conf %config(noreplace) %{_sysconfdir}/request-key.d/cifs.spnego.conf %if 0%{?centos_version} > 599 || 0%{?fedora_version} > 14 || 0%{?mandriva_version} > 201100 || 0%{?rhel_version} > 599 || 0%{?suse_version} > 1020 diff --git a/mkinitrd_scripts_boot-cifs.sh b/mkinitrd_scripts_boot-cifs.sh deleted file mode 100644 index 54a56c5..0000000 --- a/mkinitrd_scripts_boot-cifs.sh +++ /dev/null @@ -1,50 +0,0 @@ -#!/bin/bash -#%stage: block -#%modules: cifs -#%programs: /sbin/mount.cifs -#%if: "$rootfstype" = "cifs" -# -##### CIFS support -## -## This is where CIFS gets mounted. -## -## Command line parameters -## ----------------------- -## -## root=cifs://[user:pass@]/ the cifs root path -## cifsuser= (only used if not defined in root=) -## cifspass= (only used if not defined in root=) -## - -if [ "$rootfstype" = "cifs" ]; then - # load the cifs module before using it - load_modules - - if [ "${rootdev%%://*}" = "cifs" ]; then # URL parsing - rootdev=${rootdev##cifs://} - username=${rootdev%@*} - password=${username#*:} - if [ "$password" ]; then - cifspass=$password - username=${username%:*} - fi - cifsuser=$username - if [ "$username" ]; then - rootdev="${rootdev#*@}" - fi - rootdev="//$rootdev" - fi - - rootfsmod= - if [ ! "$cifsuser" -o ! "$cifspass" ]; then - echo "For CIFS support you need to specify a username and password either in the cifsuser and cifspass commandline parameters or in the root= CIFS URL." - fi - if [ "$rootflags" ] ; then - rootflags="${rootflags},user=$cifsuser" - else - rootflags="user=$cifsuser" - fi - rootflags="$rootflags,pass=$cifspass" -else - dont_load_modules -fi diff --git a/mkinitrd_scripts_setup-cifs.sh b/mkinitrd_scripts_setup-cifs.sh deleted file mode 100644 index 3a261c4..0000000 --- a/mkinitrd_scripts_setup-cifs.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/bash -# -#%stage: device -# - -if [ "$rootfstype" = "cifs" ]; then - interface=default - save_var rootfstype -fi