Hello community, here is the log from the commit of package open-vm-tools for openSUSE:Factory checked in at 2015-01-06 09:07:03 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/open-vm-tools (Old) and /work/SRC/openSUSE:Factory/.open-vm-tools.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "open-vm-tools" Changes: -------- New Changes file: --- /dev/null 2014-12-25 22:38:16.200041506 +0100 +++ /work/SRC/openSUSE:Factory/.open-vm-tools.new/open-vm-tools-KMP.changes 2015-01-06 09:07:22.000000000 +0100 @@ -0,0 +1,1007 @@ +------------------------------------------------------------------- +Mon Jan 5 10:07:50 UTC 2015 - dims...@opensuse.org + +- Add open-vm-tools-linux-3.17.7.patch: Fix building of vmhgfs with + Kernel 3.17.7+. +- Add open-vm-tools-linux-3.18.0.patch: Fix building of vmhgfs with + Kernel 3.18.0+. + +------------------------------------------------------------------- +Mon Jan 5 08:42:04 UTC 2015 - dims...@opensuse.org + +- Split building of KMPs into own spec file: open-vm-tools-KMP: + the resulting KMP packages keep their existing name, as this is + handled through the kernel_package macros. This split allows to + work around boo#905420. + +------------------------------------------------------------------- +Sat Nov 29 19:40:00 UTC 2014 - Led <led...@gmail.com> + +- fix bashisms in vmware-user-autostart-wrapper script + +------------------------------------------------------------------- +Wed Nov 12 10:04:48 UTC 2014 - dims...@opensuse.org + +- Add open-vm-tools-linux-3.17.patch: Fix build with Linux 3.17.0. + +------------------------------------------------------------------- +Mon Nov 10 16:01:56 UTC 2014 - dims...@opensuse.org + +- Sync up patches with ArchLinux: + + Added 0001-Remove-unused-DEPRECATED-macro.patch + + Added 0002-Conditionally-define-g_info-macro.patch + + Added 0003-Add-kuid_t-kgid_t-compatibility-layer.patch + + Added 0004-Use-new-link-helpers.patch + + Added 0005-Update-hgfs-file-operations-for-newer-kernels.patch + + Added 0006-Fix-vmxnet-module-on-kernels-3.16.patch + + Added 0007-Fix-vmhgfs-module-on-kernels-3.16.patch + + Added 0008-Fix-segfault-in-vmhgfs.patch + + Droped g_info_redefine.patch (now named + 0002-Conditionally-define-g_info-macro.patch). +- Enable building of KMP packages. + +------------------------------------------------------------------- +Mon Nov 10 01:03:00 UTC 2014 - Led <led...@gmail.com> + +- Fix bashisms in preun script. + +------------------------------------------------------------------- +Fri Oct 31 00:34:20 UTC 2014 - crrodrig...@opensuse.org + +- Do not generate timestamps in the doxygen docs. + +------------------------------------------------------------------- +Mon Oct 20 15:35:41 UTC 2014 - dims...@opensuse.org + +- Add -Wno-cpp to CFLAGS. + +------------------------------------------------------------------- +Mon Oct 6 22:25:36 UTC 2014 - bo...@steki.net + +- Updated to latest release 9.4.6-1770165 + + Release matching the vSphere 5.5p02 release +- "which" as separate package does not exist on older opensuse versions + so removed from Requires for older distributions +- used autoreconf as source package does not provide configure script anymore +- removed vmsync module from OS12.3 build target as it does not compile + +------------------------------------------------------------------- +Fri May 16 16:57:16 UTC 2014 - mlati...@suse.com + +- Modify vmware-user-autostart-wrapper to unconditionally start + vmware-user-suid-wrapper, and no longer delay for vmblock-fuse + if under systemd. (bnc#876074) + +------------------------------------------------------------------- +Wed May 14 15:40:19 UTC 2014 - meiss...@suse.com + +- added forgotten %pre snippet for service addition, this made + systemd service not auto-start. bnc#870737 + +------------------------------------------------------------------- +Thu Apr 28 15:33:55 UTC 2014 - mlati...@suse.com + +- Move 'vm-support' script from /etc/vmware-tools to /usr/bin (bnc#874931). +- Update call to "tools.set.version" RPC during uninstall to match upstream + behavior (bnc#875129). +- Add missing RPM runtime dependencies (net-tools, tar, which). + +------------------------------------------------------------------- +Tue Mar 17 21:52:29 UTC 2014 - mlati...@suse.com + +- Update to version 9.4.0: + + Release of open-vm-tools matching vSphere 5.5. +- Remove build dependency on liburiparser (no longer necessary). +- Removed obsolete --disable-unity configure option. +- Use doxygen to generate devel docs. +- Require libprocps for openSUSE 12.3 and above. +- Added CUSTOM_PROCPS_NAME=procps (required for 9.4.0 build). +- Add g_info_redefine.patch: Fix redefine warnings during build. +- Add vmtoolsd.service for use with systemd. +- Drop open-vm-tools.permissions: No longer required. +- Only build kmp for specified distributions, and only require kernel-source + when kernel modules are being built. +- Rename -gui package to -desktop. + +------------------------------------------------------------------- +Sat Nov 2 13:40:15 UTC 2013 - dims...@opensuse.org + +- Supplement the -gui package on xorg-x11-server instead of + xorg-x11 as the latter is only a meta-package, that is not + installed on all machines (bnc#848505). + +------------------------------------------------------------------- +Tue Sep 10 18:50:47 UTC 2013 - dims...@opensuse.org + +- Really drop open-vm-tools-kernel-3.8.patch (osc rm). +- Drop open-vm-tools-kernel-3.6.patch: fixed upstream. +- Inject -Wno-unused-local-typedefs into CFLAGS. +- Only build vmsync up to openSUSE 12.3. +- Disable build of vmhgfs (and related tools) on openSUSE > 12.3, + as the module fails and VMWare is unresponsive in providing a + fix. Maybe one day, when there is actual commitment, the module + and the related tools / mount-helpers can be re-enabled (see also + bnc#834369). +- Wrap the KMP Package in a condition to only build when there are + actually modules to be built (vm_modules not empty). +- Do not require vmware-guest-kmp from the main package if we do + not built KMP packages (if there are no modules to be built). + +------------------------------------------------------------------- +Mon May 13 15:30:52 UTC 2013 - dims...@opensuse.org + +- Update to version 9.2.3: + + Fixes for HGFS driver to compile on newer kernels (3.9). + + Fix for HGFS performance regression.. + + vmci/vsock drivers are disabled on kernels 3.9 and above. + + vmblock driver is disabled on kernels 3.0+. + + Fix and re-enable Copy/Paste on Solaris. + + Configure script will detect procsps-ng library. + + Suppress deprecated warnings coming form newer glib. +- Drop open-vm-tools-kernel-3.8.patch: fixed upstream. +- No longer build vmci and vsock for openSUSE > 12.3; they have + been included in the mainline kernel. + +------------------------------------------------------------------- +Wed Apr 24 19:57:20 UTC 2013 - dims...@opensuse.org + +- Add open-vm-tools-kernel-3.8.patch: Fix build with kernel 3.8.x. + +------------------------------------------------------------------- +Wed Apr 3 18:26:54 UTC 2013 - dims...@opensuse.org + +- Update to version 9.2.0: + + Fixes for HGFS driver to compile on newer kernels (3.6). + + vmsync driver is disabled on kernels 3.0+ as vmbackup plugin + uses FIFREEZE/FITHAW standard ioctls. + + Fixes for Copy/Paste (and C&P is temporarily disabled on + Solaris due to C++ library issues). +- Rebase open-vm-tools-kernel-3.6.patch: mostly fixed upstream. +- No longer build vmblock.ko: it's been obsoleted in favor of + vmblock-fuse. +- Change vmtoolsd to use vmware-vmblock-fuse instead of vmblock.ko, + using the new mount point /var/run/vmblock-fuse. +- Add fuse Requires, as we now use vmblock-fuse. +* Fixes bnc#803157. + +------------------------------------------------------------------- +Sat Mar 2 08:16:26 UTC 2013 - co...@suse.com + +- update license to new format + +------------------------------------------------------------------- +Fri Oct 12 08:19:01 UTC 2012 - dims...@opensuse.org + +- Update to version 9.2.0: + + Release of open-vm-tools matching Workstation 9.0. +- Drop kernel-3_4.patch: fixed upstream. +- Add open-vm-tools-kernel-3.6.patch: Fix build with kernel 3.6. +- Add pkgconfig(fuse) BuildRequires: Support vmhgfs fuse. + +------------------------------------------------------------------- +Sat Aug 4 10:45:41 UTC 2012 - dims...@opensuse.org + +- autostart-wrapper: unset SESSION_MANAGER. This helps newer + gnome-session versions to not try to track this task. Due to the + double fork() it gets it wrong and delays logout (waiting for a + timeout to terminate this user task) (bgo#681904). + +------------------------------------------------------------------- +Fri Jun 8 12:04:35 UTC 2012 - jreidin...@suse.com + +- Add kernel-3_4.patch: Fix build for kernel-3.4. + +------------------------------------------------------------------- +Fri Apr 6 21:18:39 UTC 2012 - dims...@opensuse.org + +- Update to version 8.8.2: ++++ 810 more lines (skipped) ++++ between /dev/null ++++ and /work/SRC/openSUSE:Factory/.open-vm-tools.new/open-vm-tools-KMP.changes --- /work/SRC/openSUSE:Factory/open-vm-tools/open-vm-tools.changes 2014-05-20 14:23:06.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.open-vm-tools.new/open-vm-tools.changes 2015-01-06 09:07:22.000000000 +0100 @@ -1,0 +2,67 @@ +Mon Jan 5 10:07:50 UTC 2015 - dims...@opensuse.org + +- Add open-vm-tools-linux-3.17.7.patch: Fix building of vmhgfs with + Kernel 3.17.7+. +- Add open-vm-tools-linux-3.18.0.patch: Fix building of vmhgfs with + Kernel 3.18.0+. + +------------------------------------------------------------------- +Mon Jan 5 08:42:04 UTC 2015 - dims...@opensuse.org + +- Split building of KMPs into own spec file: open-vm-tools-KMP: + the resulting KMP packages keep their existing name, as this is + handled through the kernel_package macros. This split allows to + work around boo#905420. + +------------------------------------------------------------------- +Sat Nov 29 19:40:00 UTC 2014 - Led <led...@gmail.com> + +- fix bashisms in vmware-user-autostart-wrapper script + +------------------------------------------------------------------- +Wed Nov 12 10:04:48 UTC 2014 - dims...@opensuse.org + +- Add open-vm-tools-linux-3.17.patch: Fix build with Linux 3.17.0. + +------------------------------------------------------------------- +Mon Nov 10 16:01:56 UTC 2014 - dims...@opensuse.org + +- Sync up patches with ArchLinux: + + Added 0001-Remove-unused-DEPRECATED-macro.patch + + Added 0002-Conditionally-define-g_info-macro.patch + + Added 0003-Add-kuid_t-kgid_t-compatibility-layer.patch + + Added 0004-Use-new-link-helpers.patch + + Added 0005-Update-hgfs-file-operations-for-newer-kernels.patch + + Added 0006-Fix-vmxnet-module-on-kernels-3.16.patch + + Added 0007-Fix-vmhgfs-module-on-kernels-3.16.patch + + Added 0008-Fix-segfault-in-vmhgfs.patch + + Droped g_info_redefine.patch (now named + 0002-Conditionally-define-g_info-macro.patch). +- Enable building of KMP packages. + +------------------------------------------------------------------- +Mon Nov 10 01:03:00 UTC 2014 - Led <led...@gmail.com> + +- Fix bashisms in preun script. + +------------------------------------------------------------------- +Fri Oct 31 00:34:20 UTC 2014 - crrodrig...@opensuse.org + +- Do not generate timestamps in the doxygen docs. + +------------------------------------------------------------------- +Mon Oct 20 15:35:41 UTC 2014 - dims...@opensuse.org + +- Add -Wno-cpp to CFLAGS. + +------------------------------------------------------------------- +Mon Oct 6 22:25:36 UTC 2014 - bo...@steki.net + +- Updated to latest release 9.4.6-1770165 + + Release matching the vSphere 5.5p02 release +- "which" as separate package does not exist on older opensuse versions + so removed from Requires for older distributions +- used autoreconf as source package does not provide configure script anymore +- removed vmsync module from OS12.3 build target as it does not compile + +------------------------------------------------------------------- Old: ---- g_info_redefine.patch open-vm-tools-9.4.0-1280544.tar.gz New: ---- 0001-Remove-unused-DEPRECATED-macro.patch 0002-Conditionally-define-g_info-macro.patch 0003-Add-kuid_t-kgid_t-compatibility-layer.patch 0004-Use-new-link-helpers.patch 0005-Update-hgfs-file-operations-for-newer-kernels.patch 0006-Fix-vmxnet-module-on-kernels-3.16.patch 0007-Fix-vmhgfs-module-on-kernels-3.16.patch 0008-Fix-segfault-in-vmhgfs.patch open-vm-tools-9.4.6-1770165.tar.gz open-vm-tools-KMP.changes open-vm-tools-KMP.spec open-vm-tools-linux-3.17.7.patch open-vm-tools-linux-3.17.patch open-vm-tools-linux-3.18.0.patch pre_checkin.sh ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ open-vm-tools-KMP.spec ++++++ # # spec file for package open-vm-tools-KMP # # Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2010 Dominique Leuenberger, Amsterdam, Netherlands. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # %define with_systemd 1 %define KMP 1 # The vmhgfs modules is used with all versions %define vmhgfs vmhgfs # disable systemd if before 13.1 %if 0%{suse_version} < 1310 %define with_systemd 0 %endif # exclude AMD PCnet32 LANCE pci.id from Supplements list [bnc#397554] %define __find_supplements sh -c '/usr/lib/rpm/find-supplements %{name} | grep -v pci:v00001022d00002000' %if 0%{?suse_version} <= 1230 # Modules to be built up to openSUSE 12.3, possibly not building on newer versions. %define vm_modules1230 vmci vsock %endif %if 0%{?suse_version} <= 1220 # Modules to be built up to openSUSE 12.1, possibly not building on newer versions. %define vm_modules1220 vmsync %endif %if 0%{?suse_version} <= 1210 # Modules to be built up to openSUSE 12.1, possibly not building on newer versions. %define vm_modules1210 vmxnet %endif # Modules that have to be build up to version 12.3 (Last checked on 2012-02-05 with kernel 3.2.0) %define vm_modules %{?vm_modules1230} %{?vmhgfs} %{?vm_modules1210} %{?vm_modules1220} # X modules are lower prio upstream and once in a while fail. Offer an easy way to enable/disable them. %define with_X 1 Name: open-vm-tools-KMP %define tarname open-vm-tools Version: 9.4.6 Release: 0 %define svn_rev 1770165 Summary: Open Virtual Machine Tools License: BSD-3-Clause and GPL-2.0 and LGPL-2.1 Group: System/Emulators/PC Url: http://open-vm-tools.sourceforge.net/ Source: http://sourceforge.net/projects/open-vm-tools/files/open-vm-tools/stable-9.4.x/%{tarname}-%{version}-%{svn_rev}.tar.gz Source1: vmtoolsd Source2: vmtoolsd.service Source3: vmware-user-autostart.desktop Source5: vmware-user-autostart-wrapper Source6: open-vm-tools-modprobe.conf Source7: tools.conf Source98: preamble Patch1: 0001-Remove-unused-DEPRECATED-macro.patch Patch2: 0002-Conditionally-define-g_info-macro.patch Patch3: 0003-Add-kuid_t-kgid_t-compatibility-layer.patch Patch4: 0004-Use-new-link-helpers.patch Patch5: 0005-Update-hgfs-file-operations-for-newer-kernels.patch Patch6: 0006-Fix-vmxnet-module-on-kernels-3.16.patch Patch7: 0007-Fix-vmhgfs-module-on-kernels-3.16.patch Patch8: 0008-Fix-segfault-in-vmhgfs.patch Patch10: open-vm-tools-linux-3.17.patch Patch11: open-vm-tools-linux-3.17.7.patch Patch12: open-vm-tools-linux-3.18.0.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: gcc-c++ # don't use pkgconfig(gtk+-2.0) so we can build on SLE BuildRequires: gtk2-devel BuildRequires: gtkmm2-devel # Only require kernel packages if kernel modules are being built %if "%{?vm_modules}" != " " && %{KMP} BuildRequires: kernel-source BuildRequires: kernel-syms BuildRequires: module-init-tools %else BuildRequires: autoconf BuildRequires: automake BuildRequires: doxygen BuildRequires: libdnet-devel BuildRequires: libicu-devel BuildRequires: libtool BuildRequires: pam-devel BuildRequires: pcre-devel BuildRequires: update-desktop-files BuildRequires: xorg-x11-devel BuildRequires: pkgconfig(fuse) # libprocps is required with 12.3 and above %if 0%{?suse_version} >= 1230 BuildRequires: procps-devel %endif %if "%{?vmhgfs}" # Fuse is optional and enables vmblock-fuse BuildRequires: fuse-devel %endif %endif Requires: net-tools Requires: tar %if 0%{?suse_version} >= 1310 Requires: which %endif %if 0%{?suse_version} < 1310 Requires: vmware-guest-kmp %endif Supplements: modalias(pci:v000015ADd*sv*sd*bc*sc*i*) Requires(pre): %fillup_prereq Requires(pre): %insserv_prereq ExclusiveArch: %ix86 x86_64 %if %{KMP} %suse_kernel_module_package -n vmware-guest -p %{SOURCE98} xen um %endif %if %{with_systemd} %systemd_requires %endif %description Open Virtual Machine Tools (open-vm-tools) are the open source implementation of VMware Tools. They are a set of guest operating system virtualization components that enhance performance and user experience of virtual machines. As virtualization technology rapidly becomes mainstream, each virtualization solution provider implements their own set of tools and utilities to supplement the guest virtual machine. However, most of the implementations are proprietary and are tied to a specific virtualization platform. With the Open Virtual Machine Tools project, we are hoping to solve this and other related problems. The tools are currently composed of kernel modules for Linux and user-space programs for all VMware supported Unix-like guest operating systems. They provide several useful functions like: * File transfer between a host and guest * Improved memory management and network performance under virtualization * General mechanisms and protocols for communication between host and guests and from guest to guest %package -n vmware-guest-KMP Summary: Open Virtual Machine Tools - for VM GUESTS Group: System/Emulators/PC %description -n vmware-guest-KMP Open Virtual Machine Tools (open-vm-tools) are the open source implementation of VMware Tools. They are a set of guest operating system virtualization components that enhance performance and user experience of virtual machines. As virtualization technology rapidly becomes mainstream, each virtualization solution provider implements their own set of tools and utilities to supplement the guest virtual machine. However, most of the implementations are proprietary and are tied to a specific virtualization platform. With the Open Virtual Machine Tools project, we are hoping to solve this and other related problems. The tools are currently composed of kernel modules for Linux and user-space programs for all VMware supported Unix-like guest operating systems. They provide several useful functions like: * File transfer between a host and guest * Improved memory management and network performance under virtualization * General mechanisms and protocols for communication between host and guests and from guest to guest %if %{with_X} %package desktop Summary: User experience components for Open Virtual Machine Tools Group: System/Emulators/PC Requires: %{name}%{?_isa} = %{version}-%{release} Obsoletes: %{name}-gui < %{version} Provides: %{name}-gui = %{version} Supplements: packageand(open-vm-tools:xorg-x11-server) Requires(pre): permissions %description desktop This package contains only the user-space programs and libraries of %{name} that are essential for improved user experience of VMware virtual machines. %endif %package -n libvmtools0 Summary: Open Virtual Machine Tools - shared library Group: System/Libraries %description -n libvmtools0 This is a shared library used by several Open VM Tools components, such as vmware-toolbox-cmd and vmtoolsd (and its plugins). %package -n libvmtools-devel Summary: Open Virtual Machine Tools - Development headers Group: Development Requires: libvmtools0 = %{version} %description -n libvmtools-devel Those are the development headers for libvmtools. They are needed if you intend to create own plugins for vmtoolsd. %prep %setup -q -n %{tarname}-%{version}-%{svn_rev} chmod -x AUTHORS COPYING ChangeLog NEWS README # fix for an rpmlint warning regarding wrong line feeds sed -i -e "s/\r//" README %patch1 -p2 %patch2 -p2 %patch3 -p2 %patch4 -p2 %patch5 -p2 %patch6 -p2 %patch7 -p2 %patch8 -p2 %patch10 -p1 %patch11 -p1 %patch12 -p1 %build %if ! %{KMP} # disable warning unused-but-set-variable which will raise error because of -Werror # disable warning deprecated-declarations which will raise error because of -Werror # disable warning sizeof-pointer-memaccess which will raise error because of -Werror # (this is because of 'g_static_mutex_init' usage which is now deprecated) %if 0%{?suse_version} > 1110 export CFLAGS="%{optflags} -Wno-unused-local-typedefs -Wno-unused-but-set-variable -Wno-deprecated-declarations -Wno-sizeof-pointer-memaccess -Wno-cpp -fPIE" export CXXFLAGS="%{optflags} -Wno-unused-local-typedefs -Wno-unused-but-set-variable -Wno-deprecated-declarations -Wno-sizeof-pointer-memaccess -Wno-cpp -fPIE" %else export CFLAGS="%{optflags} -Wno-deprecated-declarations -fPIE" export CXXFLAGS="%{optflags} -Wno-deprecated-declarations -fPIE" %endif export LDFLAGS="-pie" # Required for version 9.4.0 export CUSTOM_PROCPS_NAME=procps autoreconf -fi echo 'HTML_TIMESTAMP=NO' >> docs/api/doxygen.conf %configure \ --without-kernel-modules \ --without-root-privileges \ %if 0%{?suse_version} < 1230 --without-procps \ %endif %if %{with_X} --with-x \ %else --without-x \ %endif --disable-dependency-tracking \ --disable-static make %endif # If a KMP is not being built, flavors_to_build will be undefined and no modules should be built %if "%{?flavors_to_build}" TOPDIR=$PWD cd .. mkdir -p obj for flavor in %{flavors_to_build}; do rm -rf obj/$flavor cp -r %{tarname}-%{version}-%{svn_rev} obj/$flavor pushd obj/$flavor for module in %{vm_modules}; do pushd modules/linux/$module if [ -f ../vmci/Module.symvers ]; then cp ../vmci/Module.symvers . fi make -C /usr/src/linux-obj/%{_target_cpu}/$flavor modules M=$PWD VM_CCVER=$(gcc -dumpversion) HEADER_DIR="/usr/src/linux-obj/$(uname -i)/default/include" SRCROOT=$PWD OVT_SOURCE_DIR=$TOPDIR popd done popd done %endif %install # If a KMP is not being built, flavors_to_build will be undefined and no modules can be installed %if "%{?flavors_to_build}" # let's use the kernel's own modules_install routine export INSTALL_MOD_PATH=%{buildroot} export INSTALL_MOD_DIR=updates pushd .. for flavor in %{flavors_to_build}; do pushd obj/$flavor for module in %{vm_modules}; do make -C /usr/src/linux-obj/%_target_cpu/$flavor modules_install M=$PWD/modules/linux/$module done popd done popd # fix some rights on the kernel modules, to have a complete -debuginfo package; do not fail if there are no modules left. chmod u+x %{buildroot}/lib/modules/*/updates/* || : %endif %if ! %{KMP} %if 0%{?suse_version} > 1110 %make_install %else %makeinstall %endif # Remove exec bit from config files chmod a-x %{buildroot}%{_sysconfdir}/pam.d/* # Remove unnecessary files from packaging find %{buildroot}%{_libdir} -name '*.la' -delete rm -fr %{buildroot}%{_defaultdocdir} rm -fr %{buildroot}/usr/share/doc/open-vm-tools/api rm -f docs/api/build/html/FreeSans.ttf # Move vm-support to /usr/bin (bnc#874931) mv %{buildroot}%{_sysconfdir}/vmware-tools/vm-support %{buildroot}%{_bindir} # install systemd/sysvinit init scripts and symlinks %if %{with_systemd} install -p -m 644 -D %{SOURCE2} %{buildroot}%{_unitdir}/vmtoolsd.service ln -sf service %{buildroot}%{_sbindir}/rcvmtoolsd %else install -D -m 0755 %{SOURCE1} %{buildroot}%{_sysconfdir}/init.d/vmtoolsd ln -sf ../../etc/init.d/vmtoolsd %{buildroot}%{_sbindir}/rcvmtoolsd %endif %if %{with_X} # vmware-user is started by vmware-user-suid-wrapper by xdg-autostart # unfortunately, vmware-user-suid-wrapper does not wait for it's block device # to appear. For this reason we have now a vmware-user-autostart-wrapper # which checks for /proc/fs/vmblock/dev to appear and then starts vmware-user-suid-wrapper install -D -m 0755 %{SOURCE5} %{buildroot}%{_bindir}/vmware-user-autostart-wrapper install -D -m 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/xdg/autostart/vmware-user-autostart.desktop # Install the default tools.conf install -D -m 0644 %{S:7} %{buildroot}%{_sysconfdir}/vmware-tools/tools.conf # Remove the 'disable-perl-mon=1' setting if procps is available %if 0%{?suse_version} > 1220 sed -i '/openSUSE/,+2d' %{buildroot}%{_sysconfdir}/vmware-tools/tools.conf %endif # We have our own 'safe' autostart wrapper, which checks for modules to start in autologin mode... # Thus we drop the 'original' autostartup rm %{buildroot}%{_sysconfdir}/xdg/autostart/vmware-user.desktop # handle the .destop files for translations %suse_update_desktop_file vmware-user-autostart %endif # modprobe configuration for vmnics - only include if before SLE-12 %if 0%{?suse_version} < 1315 install -D -m 0644 %{SOURCE6} %{buildroot}%{_sysconfdir}/modprobe.d/50-vmnics.conf %endif %if "%{?vmhgfs}" # fix a link pointing to the buildroot for mount.vmhgfs ( cd %{buildroot}/sbin; rm mount.vmhgfs; ln -s ..%{_sbindir}/mount.vmhgfs ) %else find %{buildroot} -name '*vmhgfs*' -delete -print %endif %endif %pre %if %{with_systemd} %service_add_pre vmtoolsd.service %endif %post /sbin/ldconfig %if %{with_systemd} %service_add_post vmtoolsd.service %else %{fillup_and_insserv -Y vmtoolsd} %endif %if %{with_X} %verifyscript desktop %verify_permissions -e /usr/bin/vmware-user-suid-wrapper %post desktop %if 0%{?suse_version} <= 1130 %run_permissions %else %set_permissions /usr/bin/vmware-user-suid-wrapper %endif %endif %preun %if %{with_systemd} %service_del_preun vmtoolsd.service %else # stop service with the old name (if exists) on update (something like %%stop_on_update) test -n "$FIRST_ARG" || FIRST_ARG=$1 if test "$FIRST_ARG" -ge 1 ; then test -f /etc/sysconfig/services && . /etc/sysconfig/services if test "$YAST_IS_RUNNING" != "instsys" ; then /etc/init.d/vmware-guestd stop > /dev/null 2>&1 || : fi fi %stop_on_removal vmtoolsd %endif # Tell VMware that open-vm-tools is being uninstalled if [ "$1" = "0" -a \ -e %{_bindir}/vmware-checkvm -a \ -e %{_bindir}/vmware-rpctool ] && \ %{_bindir}/vmware-checkvm > /dev/null 2>&1; then %{_bindir}/vmware-rpctool 'tools.set.version 0' > /dev/null 2>&1 || true fi %postun %if %{with_systemd} %service_del_postun vmtoolsd.service %else %restart_on_update vmtoolsd %insserv_cleanup %endif /sbin/ldconfig %post -n libvmtools0 -p /sbin/ldconfig %postun -n libvmtools0 -p /sbin/ldconfig %clean rm -rf %{buildroot} %if ! %{KMP} %files %defattr(-, root, root) %doc AUTHORS COPYING ChangeLog NEWS README %{_bindir}/vmtoolsd %dir %{_libdir}/%{name} %dir %{_libdir}/%{name}/plugins %dir %{_libdir}/%{name}/plugins/common %dir %{_libdir}/%{name}/plugins/vmsvc %{_libdir}/%{name}/plugins/vmsvc/libguestInfo.so %{_libdir}/%{name}/plugins/vmsvc/libpowerOps.so %{_libdir}/%{name}/plugins/vmsvc/libtimeSync.so %{_libdir}/%{name}/plugins/vmsvc/libvmbackup.so %{_libdir}/%{name}/plugins/common/libhgfsServer.so %{_libdir}/%{name}/plugins/common/libvix.so %{_bindir}/vmware-checkvm %{_bindir}/vmware-hgfsclient %{_bindir}/vmware-rpctool %{_bindir}/vmware-toolbox-cmd %{_bindir}/vmware-xferlogs %{_bindir}/vm-support %if "%{?vmhgfs}" %{_sbindir}/mount.vmhgfs /sbin/mount.vmhgfs %endif %config(noreplace) %{_sysconfdir}/pam.d/vmtoolsd %dir %{_sysconfdir}/vmware-tools %dir %{_sysconfdir}/vmware-tools/scripts %dir %{_sysconfdir}/vmware-tools/scripts/vmware %{_sysconfdir}/vmware-tools/poweroff-vm-default %{_sysconfdir}/vmware-tools/poweron-vm-default %{_sysconfdir}/vmware-tools/resume-vm-default %{_sysconfdir}/vmware-tools/scripts/vmware/network %{_sysconfdir}/vmware-tools/statechange.subr %{_sysconfdir}/vmware-tools/suspend-vm-default %config(noreplace) %{_sysconfdir}/vmware-tools/tools.conf %if 0%{?suse_version} < 1315 %dir %{_sysconfdir}/modprobe.d %config %{_sysconfdir}/modprobe.d/50-vmnics.conf %endif %{_datadir}/%{name}/ %if %{with_systemd} %{_unitdir}/vmtoolsd.service %else %{_sysconfdir}/init.d/vmtoolsd %endif %{_sbindir}/rcvmtoolsd %exclude %{_libdir}/*.so %if %{with_X} %files desktop %defattr(-, root, root) %{_sysconfdir}/xdg/autostart/vmware-user-autostart.desktop %verify(not mode) %attr(0755, root, root) %{_bindir}/vmware-user-suid-wrapper %{_libdir}/%{name}/plugins/vmusr/ %{_bindir}/vmware-user-autostart-wrapper %{_bindir}/vmware-vmblock-fuse %endif %files -n libvmtools0 %defattr(-, root, root) %{_libdir}/libvmtools.so.* %{_libdir}/libguestlib.so.* %{_libdir}/libhgfs.so.* %files -n libvmtools-devel %defattr(-,root,root) %doc docs/api/build/* %{_includedir}/vmGuestLib %{_libdir}/*.so %{_libdir}/pkgconfig/vmguestlib.pc %endif %changelog ++++++ open-vm-tools.spec ++++++ --- /var/tmp/diff_new_pack.X0XYFX/_old 2015-01-06 09:07:23.000000000 +0100 +++ /var/tmp/diff_new_pack.X0XYFX/_new 2015-01-06 09:07:23.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package open-vm-tools # -# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2010 Dominique Leuenberger, Amsterdam, Netherlands. # # All modifications and additions to the file contributed by third parties @@ -18,11 +18,10 @@ %define with_systemd 1 +%define KMP 0 -# vmhgfs modules does not build on kernel 3.11 -%if 0%{suse_version} < 1310 +# The vmhgfs modules is used with all versions %define vmhgfs vmhgfs -%endif # disable systemd if before 13.1 %if 0%{suse_version} < 1310 @@ -32,31 +31,37 @@ # exclude AMD PCnet32 LANCE pci.id from Supplements list [bnc#397554] %define __find_supplements sh -c '/usr/lib/rpm/find-supplements %{name} | grep -v pci:v00001022d00002000' -%if 0%{?suse_version} <= 1210 +%if 0%{?suse_version} <= 1230 +# Modules to be built up to openSUSE 12.3, possibly not building on newer versions. +%define vm_modules1230 vmci vsock +%endif + +%if 0%{?suse_version} <= 1220 # Modules to be built up to openSUSE 12.1, possibly not building on newer versions. -%define vm_modules1210 vmxnet +%define vm_modules1220 vmsync %endif -%if 0%{?suse_version} <= 1230 -# Modules to be built up to openSUSE 12.3, possibly not building on newer versions. -%define vm_modules1230 vmci vsock vmsync +%if 0%{?suse_version} <= 1210 +# Modules to be built up to openSUSE 12.1, possibly not building on newer versions. +%define vm_modules1210 vmxnet %endif # Modules that have to be build up to version 12.3 (Last checked on 2012-02-05 with kernel 3.2.0) -%define vm_modules %{?vm_modules1230} %{?vmhgfs} %{?vm_modules1210} +%define vm_modules %{?vm_modules1230} %{?vmhgfs} %{?vm_modules1210} %{?vm_modules1220} # X modules are lower prio upstream and once in a while fail. Offer an easy way to enable/disable them. %define with_X 1 Name: open-vm-tools -Version: 9.4.0 +%define tarname open-vm-tools +Version: 9.4.6 Release: 0 -%define svn_rev 1280544 +%define svn_rev 1770165 Summary: Open Virtual Machine Tools License: BSD-3-Clause and GPL-2.0 and LGPL-2.1 Group: System/Emulators/PC Url: http://open-vm-tools.sourceforge.net/ -Source: http://sourceforge.net/projects/open-vm-tools/files/open-vm-tools/stable-9.4.x/%{name}-%{version}-%{svn_rev}.tar.gz +Source: http://sourceforge.net/projects/open-vm-tools/files/open-vm-tools/stable-9.4.x/%{tarname}-%{version}-%{svn_rev}.tar.gz Source1: vmtoolsd Source2: vmtoolsd.service Source3: vmware-user-autostart.desktop @@ -64,22 +69,34 @@ Source6: open-vm-tools-modprobe.conf Source7: tools.conf Source98: preamble -# PATCH-FIX-UPSTREAM g_info_redefine.patch (RHBZ#1063847) -Patch0: g_info_redefine.patch +Patch1: 0001-Remove-unused-DEPRECATED-macro.patch +Patch2: 0002-Conditionally-define-g_info-macro.patch +Patch3: 0003-Add-kuid_t-kgid_t-compatibility-layer.patch +Patch4: 0004-Use-new-link-helpers.patch +Patch5: 0005-Update-hgfs-file-operations-for-newer-kernels.patch +Patch6: 0006-Fix-vmxnet-module-on-kernels-3.16.patch +Patch7: 0007-Fix-vmhgfs-module-on-kernels-3.16.patch +Patch8: 0008-Fix-segfault-in-vmhgfs.patch +Patch10: open-vm-tools-linux-3.17.patch +Patch11: open-vm-tools-linux-3.17.7.patch +Patch12: open-vm-tools-linux-3.18.0.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: gcc-c++ # don't use pkgconfig(gtk+-2.0) so we can build on SLE BuildRequires: gtk2-devel BuildRequires: gtkmm2-devel # Only require kernel packages if kernel modules are being built -%if "%{?vm_modules}" != " " +%if "%{?vm_modules}" != " " && %{KMP} BuildRequires: kernel-source BuildRequires: kernel-syms -%endif +BuildRequires: module-init-tools +%else +BuildRequires: autoconf +BuildRequires: automake BuildRequires: doxygen BuildRequires: libdnet-devel BuildRequires: libicu-devel -BuildRequires: module-init-tools +BuildRequires: libtool BuildRequires: pam-devel BuildRequires: pcre-devel BuildRequires: update-desktop-files @@ -93,20 +110,21 @@ # Fuse is optional and enables vmblock-fuse BuildRequires: fuse-devel %endif +%endif Requires: net-tools Requires: tar +%if 0%{?suse_version} >= 1310 Requires: which +%endif %if 0%{?suse_version} < 1310 Requires: vmware-guest-kmp %endif Supplements: modalias(pci:v000015ADd*sv*sd*bc*sc*i*) Requires(pre): %fillup_prereq Requires(pre): %insserv_prereq -Requires(pre): permissions ExclusiveArch: %ix86 x86_64 -# Only build KMP on versions below 13.1 -%if 0%{?suse_version} < 1310 +%if %{KMP} %suse_kernel_module_package -n vmware-guest -p %{SOURCE98} xen um %endif @@ -201,19 +219,31 @@ if you intend to create own plugins for vmtoolsd. %prep -%setup -q -n %{name}-%{version}-%{svn_rev} +%setup -q -n %{tarname}-%{version}-%{svn_rev} chmod -x AUTHORS COPYING ChangeLog NEWS README # fix for an rpmlint warning regarding wrong line feeds sed -i -e "s/\r//" README -%patch0 -p1 -b .g_info +%patch1 -p2 +%patch2 -p2 +%patch3 -p2 +%patch4 -p2 +%patch5 -p2 +%patch6 -p2 +%patch7 -p2 +%patch8 -p2 +%patch10 -p1 +%patch11 -p1 +%patch12 -p1 %build +%if ! %{KMP} # disable warning unused-but-set-variable which will raise error because of -Werror # disable warning deprecated-declarations which will raise error because of -Werror +# disable warning sizeof-pointer-memaccess which will raise error because of -Werror # (this is because of 'g_static_mutex_init' usage which is now deprecated) %if 0%{?suse_version} > 1110 -export CFLAGS="%{optflags} -Wno-unused-local-typedefs -Wno-unused-but-set-variable -Wno-deprecated-declarations -fPIE" -export CXXFLAGS="%{optflags} -Wno-unused-local-typedefs -Wno-unused-but-set-variable -Wno-deprecated-declarations -fPIE" +export CFLAGS="%{optflags} -Wno-unused-local-typedefs -Wno-unused-but-set-variable -Wno-deprecated-declarations -Wno-sizeof-pointer-memaccess -Wno-cpp -fPIE" +export CXXFLAGS="%{optflags} -Wno-unused-local-typedefs -Wno-unused-but-set-variable -Wno-deprecated-declarations -Wno-sizeof-pointer-memaccess -Wno-cpp -fPIE" %else export CFLAGS="%{optflags} -Wno-deprecated-declarations -fPIE" export CXXFLAGS="%{optflags} -Wno-deprecated-declarations -fPIE" @@ -221,6 +251,8 @@ export LDFLAGS="-pie" # Required for version 9.4.0 export CUSTOM_PROCPS_NAME=procps +autoreconf -fi +echo 'HTML_TIMESTAMP=NO' >> docs/api/doxygen.conf %configure \ --without-kernel-modules \ --without-root-privileges \ @@ -235,6 +267,7 @@ --disable-dependency-tracking \ --disable-static make +%endif # If a KMP is not being built, flavors_to_build will be undefined and no modules should be built %if "%{?flavors_to_build}" @@ -243,7 +276,7 @@ mkdir -p obj for flavor in %{flavors_to_build}; do rm -rf obj/$flavor - cp -r %{name}-%{version}-%{svn_rev} obj/$flavor + cp -r %{tarname}-%{version}-%{svn_rev} obj/$flavor pushd obj/$flavor for module in %{vm_modules}; do pushd modules/linux/$module @@ -277,6 +310,7 @@ chmod u+x %{buildroot}/lib/modules/*/updates/* || : %endif +%if ! %{KMP} %if 0%{?suse_version} > 1110 %make_install %else @@ -339,17 +373,14 @@ find %{buildroot} -name '*vmhgfs*' -delete -print %endif +%endif + %pre %if %{with_systemd} %service_add_pre vmtoolsd.service %endif %post -%if 0%{?suse_version} <= 1130 -%run_permissions -%else -%set_permissions /usr/bin/vmware-user-suid-wrapper -%endif /sbin/ldconfig %if %{with_systemd} %service_add_post vmtoolsd.service @@ -380,7 +411,7 @@ if test "$FIRST_ARG" -ge 1 ; then test -f /etc/sysconfig/services && . /etc/sysconfig/services if test "$YAST_IS_RUNNING" != "instsys" ; then - /etc/init.d/vmware-guestd stop &> /dev/null || : + /etc/init.d/vmware-guestd stop > /dev/null 2>&1 || : fi fi %stop_on_removal vmtoolsd @@ -389,8 +420,8 @@ if [ "$1" = "0" -a \ -e %{_bindir}/vmware-checkvm -a \ -e %{_bindir}/vmware-rpctool ] && \ - %{_bindir}/vmware-checkvm &> /dev/null; then - %{_bindir}/vmware-rpctool 'tools.set.version 0' &> /dev/null || /bin/true + %{_bindir}/vmware-checkvm > /dev/null 2>&1; then + %{_bindir}/vmware-rpctool 'tools.set.version 0' > /dev/null 2>&1 || true fi %postun @@ -409,6 +440,7 @@ %clean rm -rf %{buildroot} +%if ! %{KMP} %files %defattr(-, root, root) %doc AUTHORS COPYING ChangeLog NEWS README @@ -445,6 +477,7 @@ %{_sysconfdir}/vmware-tools/suspend-vm-default %config(noreplace) %{_sysconfdir}/vmware-tools/tools.conf %if 0%{?suse_version} < 1315 +%dir %{_sysconfdir}/modprobe.d %config %{_sysconfdir}/modprobe.d/50-vmnics.conf %endif %{_datadir}/%{name}/ @@ -461,7 +494,7 @@ %files desktop %defattr(-, root, root) %{_sysconfdir}/xdg/autostart/vmware-user-autostart.desktop -%verify(not mode) %attr(0755,root,root) %{_bindir}/vmware-user-suid-wrapper +%verify(not mode) %attr(0755, root, root) %{_bindir}/vmware-user-suid-wrapper %{_libdir}/%{name}/plugins/vmusr/ %{_bindir}/vmware-user-autostart-wrapper %{_bindir}/vmware-vmblock-fuse @@ -479,5 +512,6 @@ %{_includedir}/vmGuestLib %{_libdir}/*.so %{_libdir}/pkgconfig/vmguestlib.pc +%endif %changelog ++++++ 0001-Remove-unused-DEPRECATED-macro.patch ++++++ >From 0a49c04428ff99fdf29edf32e043e04fae492b6d Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Mon, 14 Jul 2014 11:24:44 -0400 Subject: [PATCH 1/5] Remove unused DEPRECATED macro --- open-vm-tools/lib/include/vm_assert.h | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/open-vm-tools/lib/include/vm_assert.h b/open-vm-tools/lib/include/vm_assert.h index 5b02eed..48c9f1d 100644 --- a/open-vm-tools/lib/include/vm_assert.h +++ b/open-vm-tools/lib/include/vm_assert.h @@ -282,16 +282,6 @@ void WarningThrottled(uint32 *count, const char *fmt, ...) #define LOG_ONCE(_s) DO_ONCE(Log _s) -#ifdef VMX86_DEVEL - #define DEPRECATED(_fix) DO_ONCE( \ - Warning("%s:%d: %s is DEPRECATED; %s\n", \ - __FILE__, __LINE__, __FUNCTION__, \ - _fix)) -#else - #define DEPRECATED(_fix) do {} while (0) -#endif - - /* * Redefine macros that are only in debug versions */ -- 2.0.1 ++++++ 0002-Conditionally-define-g_info-macro.patch ++++++ >From 9a38a9da20c898c4c21e84e1cf4f97c5b63f6a87 Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Mon, 14 Jul 2014 11:25:10 -0400 Subject: [PATCH 2/5] Conditionally define g_info macro * Some versions of GLib define this macro. --- open-vm-tools/lib/include/vmware/tools/log.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/open-vm-tools/lib/include/vmware/tools/log.h b/open-vm-tools/lib/include/vmware/tools/log.h index 526b7c2..fa7deb4 100644 --- a/open-vm-tools/lib/include/vmware/tools/log.h +++ b/open-vm-tools/lib/include/vmware/tools/log.h @@ -121,6 +121,7 @@ # define FUNC __FUNCTION__ #endif +#ifndef g_info /* ******************************************************************************* * g_info -- */ /** @@ -135,7 +136,7 @@ */ #define g_info(fmt, ...) g_log(G_LOG_DOMAIN, G_LOG_LEVEL_INFO, fmt, ## __VA_ARGS__) - +#endif /* ******************************************************************************* -- 2.0.1 ++++++ 0003-Add-kuid_t-kgid_t-compatibility-layer.patch ++++++ >From 327938705e9223cdc15c5e0d85b0cdfafb4b6cd7 Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Sun, 13 Jul 2014 18:19:35 -0400 Subject: [PATCH 3/5] Add kuid_t/kgid_t compatibility layer --- open-vm-tools/modules/linux/vmhgfs/filesystem.c | 20 ++-- open-vm-tools/modules/linux/vmhgfs/fsutil.c | 118 ++++++++++++++++++++---- open-vm-tools/modules/linux/vmhgfs/fsutil.h | 5 +- open-vm-tools/modules/linux/vmhgfs/inode.c | 18 +++- open-vm-tools/modules/linux/vmhgfs/module.h | 14 ++- 5 files changed, 145 insertions(+), 30 deletions(-) diff --git a/open-vm-tools/modules/linux/vmhgfs/filesystem.c b/open-vm-tools/modules/linux/vmhgfs/filesystem.c index f101ca7..c845b36 100644 --- a/open-vm-tools/modules/linux/vmhgfs/filesystem.c +++ b/open-vm-tools/modules/linux/vmhgfs/filesystem.c @@ -228,17 +228,25 @@ HgfsInitSuperInfo(HgfsMountInfo *mountInfo) // IN: Passed down from the user * or gid given to us by the server. */ si->uidSet = mountInfo->uidSet; + si->uid = current_uid(); if (si->uidSet) { - si->uid = mountInfo->uid; - } else { - si->uid = current_uid(); + kuid_t mntUid = make_kuid(current_user_ns(), mountInfo->uid); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 5, 0) + if (uid_valid(mntUid)) +#endif + si->uid = mntUid; } + si->gidSet = mountInfo->gidSet; + si->gid = current_gid(); if (si->gidSet) { - si->gid = mountInfo->gid; - } else { - si->gid = current_gid(); + kgid_t mntGid = make_kgid(current_user_ns(), mountInfo->gid); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 5, 0) + if (gid_valid(mntGid)) +#endif + si->gid = mntGid; } + si->fmask = mountInfo->fmask; si->dmask = mountInfo->dmask; si->ttl = mountInfo->ttl * HZ; // in ticks diff --git a/open-vm-tools/modules/linux/vmhgfs/fsutil.c b/open-vm-tools/modules/linux/vmhgfs/fsutil.c index 28858bc..1028cc9 100644 --- a/open-vm-tools/modules/linux/vmhgfs/fsutil.c +++ b/open-vm-tools/modules/linux/vmhgfs/fsutil.c @@ -545,6 +545,105 @@ HgfsUnpackCommonAttr(HgfsReq *req, // IN: Reply packet /* *---------------------------------------------------------------------- * + * HgfsCalcBlockSize -- + * + * Calculate the number of 512 byte blocks used. + * + * Round the size to the next whole block and divide by the block size + * to get the number of 512 byte blocks. + * Note, this is taken from the nfs client and is simply performing: + * (size + 512-1)/ 512) + * + * Results: + * The number of 512 byte blocks for the size. + * + * Side effects: + * None + * + *---------------------------------------------------------------------- + */ +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 17) +static inline blkcnt_t +HgfsCalcBlockSize(uint64 tsize) +{ + blkcnt_t used = (tsize + 511) >> 9; + return (used > ULONG_MAX) ? ULONG_MAX : used; +} +#else +static inline unsigned long +HgfsCalcBlockSize(uint64 tsize) +{ + loff_t used = (tsize + 511) >> 9; + return (used > ULONG_MAX) ? ULONG_MAX : used; +} +#endif + +/* + *---------------------------------------------------------------------- + * + * HgfsSetInodeUidGid -- + * + * Set the UID and GID of the inode. + * + * Update an inode's UID and GID to match those of the HgfsAttr returned + * by the server. + * + * Results: + * The number of 512 byte blocks for the size. + * + * Side effects: + * None + * + *---------------------------------------------------------------------- + */ + +static void +HgfsSetInodeUidGid(struct inode *inode, // IN/OUT: Inode + HgfsSuperInfo *si, // IN: New attrs + HgfsAttrInfo const *attr) // IN: New attrs +{ + /* + * Use the stored uid and gid if we were given them at mount-time, or if + * the server didn't give us a uid or gid. + */ + if (si->uidSet || (attr->mask & HGFS_ATTR_VALID_USERID) == 0) { + inode->i_uid = si->uid; + } else { + kuid_t attrUid = make_kuid(&init_user_ns, attr->userId); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 5, 0) + if (uid_valid(attrUid)) { + inode->i_uid = attrUid; + } else { + inode->i_uid = si->uid; + } +#else + inode->i_uid = attrUid; +#endif + LOG(6, (KERN_DEBUG "VMware hgfs: %s: inode uid %u\n", + __func__, from_kuid(&init_user_ns, inode->i_uid))); + } + if (si->gidSet || (attr->mask & HGFS_ATTR_VALID_GROUPID) == 0) { + inode->i_gid = si->gid; + } else { + kgid_t attrGid = make_kgid(&init_user_ns, attr->groupId); +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 5, 0) + if (gid_valid(attrGid)) { + inode->i_gid = attrGid; + } else { + inode->i_gid = si->gid; + } +#else + inode->i_gid = attrGid; +#endif + LOG(6, (KERN_DEBUG "VMware hgfs: %s: inode gid %u\n", + __func__, from_kgid(&init_user_ns, inode->i_gid))); + } +} + + +/* + *---------------------------------------------------------------------- + * * HgfsChangeFileAttributes -- * * Update an inode's attributes to match those of the HgfsAttr. May @@ -634,20 +733,7 @@ HgfsChangeFileAttributes(struct inode *inode, // IN/OUT: Inode */ set_nlink(inode, 1); - /* - * Use the stored uid and gid if we were given them at mount-time, or if - * the server didn't give us a uid or gid. - */ - if (si->uidSet || (attr->mask & HGFS_ATTR_VALID_USERID) == 0) { - inode->i_uid = si->uid; - } else { - inode->i_uid = attr->userId; - } - if (si->gidSet || (attr->mask & HGFS_ATTR_VALID_GROUPID) == 0) { - inode->i_gid = si->gid; - } else { - inode->i_gid = attr->groupId; - } + HgfsSetInodeUidGid(inode, si, attr); inode->i_rdev = 0; /* Device nodes are not supported */ #if !defined VMW_INODE_2618 @@ -1618,8 +1704,8 @@ HgfsStatusConvertToLinux(HgfsStatus hgfsStatus) // IN: Status code to convert void HgfsSetUidGid(struct inode *parent, // IN: parent inode struct dentry *dentry, // IN: dentry of file to update - uid_t uid, // IN: uid to set - gid_t gid) // IN: gid to set + kuid_t uid, // IN: uid to set + kgid_t gid) // IN: gid to set { struct iattr setUidGid; diff --git a/open-vm-tools/modules/linux/vmhgfs/fsutil.h b/open-vm-tools/modules/linux/vmhgfs/fsutil.h index da5c5a1..2767099 100644 --- a/open-vm-tools/modules/linux/vmhgfs/fsutil.h +++ b/open-vm-tools/modules/linux/vmhgfs/fsutil.h @@ -32,6 +32,7 @@ #include <linux/signal.h> #include "compat_fs.h" +#include "module.h" /* For kuid_t kgid_t types. */ #include "inode.h" #include "request.h" #include "vm_basic_types.h" @@ -91,8 +92,8 @@ int HgfsGetHandle(struct inode *inode, int HgfsStatusConvertToLinux(HgfsStatus hgfsStatus); void HgfsSetUidGid(struct inode *parent, struct dentry *dentry, - uid_t uid, - gid_t gid); + kuid_t uid, + kgid_t gid); struct inode *HgfsGetInode(struct super_block *sb, ino_t ino); void HgfsDoReadInode(struct inode *inode); diff --git a/open-vm-tools/modules/linux/vmhgfs/inode.c b/open-vm-tools/modules/linux/vmhgfs/inode.c index 859b3ff..caaa41a 100644 --- a/open-vm-tools/modules/linux/vmhgfs/inode.c +++ b/open-vm-tools/modules/linux/vmhgfs/inode.c @@ -404,6 +404,8 @@ HgfsPackSetattrRequest(struct iattr *iattr, // IN: Inode attrs to update from size_t reqBufferSize; size_t reqSize; int result = 0; + uid_t attrUid = -1; + gid_t attrGid = -1; ASSERT(iattr); ASSERT(dentry); @@ -412,6 +414,14 @@ HgfsPackSetattrRequest(struct iattr *iattr, // IN: Inode attrs to update from valid = iattr->ia_valid; + if (valid & ATTR_UID) { + attrUid = from_kuid(&init_user_ns, iattr->ia_uid); + } + + if (valid & ATTR_GID) { + attrGid = from_kgid(&init_user_ns, iattr->ia_gid); + } + switch (opUsed) { case HGFS_OP_SETATTR_V3: { HgfsRequest *requestHeader; @@ -488,13 +498,13 @@ HgfsPackSetattrRequest(struct iattr *iattr, // IN: Inode attrs to update from if (valid & ATTR_UID) { attrV2->mask |= HGFS_ATTR_VALID_USERID; - attrV2->userId = iattr->ia_uid; + attrV2->userId = attrUid; *changed = TRUE; } if (valid & ATTR_GID) { attrV2->mask |= HGFS_ATTR_VALID_GROUPID; - attrV2->groupId = iattr->ia_gid; + attrV2->groupId = attrGid; *changed = TRUE; } @@ -591,13 +601,13 @@ HgfsPackSetattrRequest(struct iattr *iattr, // IN: Inode attrs to update from if (valid & ATTR_UID) { attrV2->mask |= HGFS_ATTR_VALID_USERID; - attrV2->userId = iattr->ia_uid; + attrV2->userId = attrUid; *changed = TRUE; } if (valid & ATTR_GID) { attrV2->mask |= HGFS_ATTR_VALID_GROUPID; - attrV2->groupId = iattr->ia_gid; + attrV2->groupId = attrGid; *changed = TRUE; } diff --git a/open-vm-tools/modules/linux/vmhgfs/module.h b/open-vm-tools/modules/linux/vmhgfs/module.h index 3e0973b..b6bcd1e 100644 --- a/open-vm-tools/modules/linux/vmhgfs/module.h +++ b/open-vm-tools/modules/linux/vmhgfs/module.h @@ -74,6 +74,16 @@ extern int LOGLEVEL_THRESHOLD; * Macros for accessing members that are private to this code in * sb/inode/file structs. */ + +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 5, 0) +typedef uid_t kuid_t; +typedef gid_t kgid_t; +#define from_kuid(_ns, _kuid) (_kuid) +#define from_kgid(_ns, _kgid) (_kgid) +#define make_kuid(_ns, _uid) (_uid) +#define make_kgid(_ns, _gid) (_gid) +#endif + #define HGFS_SET_SB_TO_COMMON(sb, common) do { (sb)->s_fs_info = (common); } while (0) #define HGFS_SB_TO_COMMON(sb) ((HgfsSuperInfo *)(sb)->s_fs_info) @@ -110,9 +120,9 @@ extern int LOGLEVEL_THRESHOLD; /* Data kept in each superblock in sb->u. */ typedef struct HgfsSuperInfo { - uid_t uid; /* UID of user who mounted this fs. */ + kuid_t uid; /* UID of user who mounted this fs. */ + kgid_t gid; /* GID of user who mounted this fs. */ Bool uidSet; /* Was the UID specified at mount-time? */ - gid_t gid; /* GID of user who mounted this fs. */ Bool gidSet; /* Was the GID specified at mount-time? */ mode_t fmask; /* File permission mask. */ mode_t dmask; /* Directory permission mask. */ -- 2.0.1 ++++++ 0004-Use-new-link-helpers.patch ++++++ >From 20437d731289126ee5363a6f73e4171d39f2e3d9 Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Mon, 14 Jul 2014 11:32:35 -0400 Subject: [PATCH 4/5] Use new link helpers * vfs_follow_link was removed in 3.12. * vfs_readlink was removed in 3.15. --- open-vm-tools/modules/linux/vmhgfs/link.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/open-vm-tools/modules/linux/vmhgfs/link.c b/open-vm-tools/modules/linux/vmhgfs/link.c index 9fb95a5..06ea953 100644 --- a/open-vm-tools/modules/linux/vmhgfs/link.c +++ b/open-vm-tools/modules/linux/vmhgfs/link.c @@ -110,9 +110,15 @@ HgfsFollowlink(struct dentry *dentry, // IN: Dentry containing link "on something that wasn't a symlink\n")); error = -EINVAL; } else { +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 12, 0) + LOG(6, (KERN_DEBUG "VMware hgfs: HgfsFollowlink: calling " + "nd_set_link\n")); + nd_set_link(nd, fileName); +#else LOG(6, (KERN_DEBUG "VMware hgfs: HgfsFollowlink: calling " "vfs_follow_link\n")); error = vfs_follow_link(nd, fileName); +#endif } kfree(fileName); } @@ -172,9 +178,18 @@ HgfsReadlink(struct dentry *dentry, // IN: Dentry containing link "on something that wasn't a symlink\n")); error = -EINVAL; } else { +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 15, 0) + LOG(6, (KERN_DEBUG "VMware hgfs: HgfsReadlink: calling " + "readlink_copy\n")); + LOG(6, (KERN_DEBUG "VMware hgfs: %s: calling " + "readlink_copy\n", + __func__)); + error = readlink_copy(buffer, buflen, fileName); +#else LOG(6, (KERN_DEBUG "VMware hgfs: HgfsReadlink: calling " "vfs_readlink\n")); error = vfs_readlink(dentry, buffer, buflen, fileName); +#endif } kfree(fileName); } -- 2.0.1 ++++++ 0005-Update-hgfs-file-operations-for-newer-kernels.patch ++++++ ++++ 2688 lines (skipped) ++++++ 0006-Fix-vmxnet-module-on-kernels-3.16.patch ++++++ >From 4601d767d60e9a377c285994266c6fef49cae550 Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Fri, 15 Aug 2014 10:40:38 -0400 Subject: [PATCH 10/11] Fix vmxnet module on kernels >= 3.16 * Add compat check for ethtool_ops in net_device struct. * SET_ETHTOOL_OPS is no longer defined, but can be manually. --- open-vm-tools/modules/linux/shared/compat_netdevice.h | 4 ++++ open-vm-tools/modules/linux/vmxnet/vmxnet.c | 13 ++++++++----- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/open-vm-tools/modules/linux/shared/compat_netdevice.h b/open-vm-tools/modules/linux/shared/compat_netdevice.h index 3aec25b..a65d59b 100644 --- a/open-vm-tools/modules/linux/shared/compat_netdevice.h +++ b/open-vm-tools/modules/linux/shared/compat_netdevice.h @@ -337,4 +337,8 @@ typedef netdev_features_t compat_netdev_features_t; typedef u32 compat_netdev_features_t; #endif +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 16, 0) || defined(SET_ETHTOOL_OPS) +#define VMW_HAVE_ETHTOOL_OPS 1 +#endif + #endif /* __COMPAT_NETDEVICE_H__ */ diff --git a/open-vm-tools/modules/linux/vmxnet/vmxnet.c b/open-vm-tools/modules/linux/vmxnet/vmxnet.c index 54b4590..7fb5692 100644 --- a/open-vm-tools/modules/linux/vmxnet/vmxnet.c +++ b/open-vm-tools/modules/linux/vmxnet/vmxnet.c @@ -283,8 +283,7 @@ vmxnet_change_mtu(struct net_device *dev, int new_mtu) #endif - -#ifdef SET_ETHTOOL_OPS +#ifdef VMW_HAVE_ETHTOOL_OPS /* *---------------------------------------------------------------------------- * @@ -530,7 +529,7 @@ vmxnet_ethtool_ops = { }; -#else /* !defined(SET_ETHTOOL_OPS) */ +#else /* !defined(VMW_HAVE_ETHTOOL_OPS) */ /* @@ -743,7 +742,7 @@ vmxnet_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) } return -EOPNOTSUPP; } -#endif /* SET_ETHTOOL_OPS */ +#endif /* !defined(VMW_HAVE_ETHTOOL_OPS) */ /* @@ -1142,8 +1141,12 @@ vmxnet_probe_device(struct pci_dev *pdev, // IN: vmxnet PCI device dev->watchdog_timeo = VMXNET_WATCHDOG_TIMEOUT; #endif -#ifdef SET_ETHTOOL_OPS +#ifdef VMW_HAVE_ETHTOOL_OPS +# ifdef SET_ETHTOOL_OPS SET_ETHTOOL_OPS(dev, &vmxnet_ethtool_ops); +# else + dev->ethtool_ops = &vmxnet_ethtool_ops; +# endif #else dev->do_ioctl = vmxnet_ioctl; #endif -- 2.0.4 ++++++ 0007-Fix-vmhgfs-module-on-kernels-3.16.patch ++++++ >From 6497dbbabb9506df8e16b60bf2cd396a8c6bb26b Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Fri, 15 Aug 2014 10:42:30 -0400 Subject: [PATCH 11/11] Fix vmhgfs module on kernels >= 3.16 * Use read_iter/write_iter file operations on kernels >= 3.16. * Do not set aio_read/aio_write on kernels >= 3.16. --- open-vm-tools/modules/linux/vmhgfs/file.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/open-vm-tools/modules/linux/vmhgfs/file.c b/open-vm-tools/modules/linux/vmhgfs/file.c index 825cebe..67606fd 100644 --- a/open-vm-tools/modules/linux/vmhgfs/file.c +++ b/open-vm-tools/modules/linux/vmhgfs/file.c @@ -76,6 +76,7 @@ static int HgfsGetOpenFlags(uint32 flags); static int HgfsOpen(struct inode *inode, struct file *file); #if defined VMW_USE_AIO +# if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) static ssize_t HgfsAioRead(struct kiocb *iocb, const struct iovec *iov, unsigned long numSegs, @@ -84,6 +85,7 @@ static ssize_t HgfsAioWrite(struct kiocb *iocb, const struct iovec *iov, unsigned long numSegs, loff_t offset); +# endif #else static ssize_t HgfsRead(struct file *file, char __user *buf, @@ -150,15 +152,20 @@ struct file_operations HgfsFileFileOperations = { .open = HgfsOpen, .llseek = HgfsSeek, .flush = HgfsFlush, -#if defined VMW_USE_AIO +#ifdef VMW_USE_AIO .read = do_sync_read, .write = do_sync_write, +# if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 16, 0) + .read_iter = generic_file_read_iter, + .write_iter = generic_file_write_iter, +# else .aio_read = HgfsAioRead, .aio_write = HgfsAioWrite, -#else +# endif +#else /* !VMW_USE_AIO */ .read = HgfsRead, .write = HgfsWrite, -#endif +#endif /* !VMW_USE_AIO */ .fsync = HgfsFsync, .mmap = HgfsMmap, .release = HgfsRelease, @@ -748,6 +755,7 @@ out: #if defined VMW_USE_AIO +# if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) /* *---------------------------------------------------------------------- * @@ -883,7 +891,7 @@ out: return result; } - +# endif /* if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) */ #else /* *---------------------------------------------------------------------- -- 2.0.4 ++++++ 0008-Fix-segfault-in-vmhgfs.patch ++++++ >From e75a7401a72607476f7a248f5a7fe4f11d6d129d Mon Sep 17 00:00:00 2001 From: "Scott M. Kroll" <skr...@gmail.com> Date: Fri, 15 Aug 2014 11:11:12 -0400 Subject: [PATCH 12/12] Fix segfault in vmhgfs * Need to use sync read/write but also set the read_iter/write_iter operations. --- open-vm-tools/modules/linux/shared/compat_fs.h | 3 ++- open-vm-tools/modules/linux/vmhgfs/file.c | 23 ++++++++++++----------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/open-vm-tools/modules/linux/shared/compat_fs.h b/open-vm-tools/modules/linux/shared/compat_fs.h index f762f6f..eb53ee7 100644 --- a/open-vm-tools/modules/linux/shared/compat_fs.h +++ b/open-vm-tools/modules/linux/shared/compat_fs.h @@ -89,7 +89,8 @@ * changed over time, so for simplicity, we'll only enable it from 2.6.19 and * on. */ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19) && \ + LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) # define VMW_USE_AIO #endif diff --git a/open-vm-tools/modules/linux/vmhgfs/file.c b/open-vm-tools/modules/linux/vmhgfs/file.c index 67606fd..fcf0681 100644 --- a/open-vm-tools/modules/linux/vmhgfs/file.c +++ b/open-vm-tools/modules/linux/vmhgfs/file.c @@ -76,7 +76,6 @@ static int HgfsGetOpenFlags(uint32 flags); static int HgfsOpen(struct inode *inode, struct file *file); #if defined VMW_USE_AIO -# if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) static ssize_t HgfsAioRead(struct kiocb *iocb, const struct iovec *iov, unsigned long numSegs, @@ -85,7 +84,6 @@ static ssize_t HgfsAioWrite(struct kiocb *iocb, const struct iovec *iov, unsigned long numSegs, loff_t offset); -# endif #else static ssize_t HgfsRead(struct file *file, char __user *buf, @@ -155,14 +153,13 @@ struct file_operations HgfsFileFileOperations = { #ifdef VMW_USE_AIO .read = do_sync_read, .write = do_sync_write, -# if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 16, 0) - .read_iter = generic_file_read_iter, - .write_iter = generic_file_write_iter, -# else .aio_read = HgfsAioRead, .aio_write = HgfsAioWrite, -# endif #else /* !VMW_USE_AIO */ +# if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 16, 0) + .read_iter = generic_file_read_iter, + .write_iter = generic_file_write_iter, +# endif .read = HgfsRead, .write = HgfsWrite, #endif /* !VMW_USE_AIO */ @@ -755,7 +752,6 @@ out: #if defined VMW_USE_AIO -# if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) /* *---------------------------------------------------------------------- * @@ -890,8 +886,6 @@ out: spin_unlock(&writeDentry->d_inode->i_lock); return result; } - -# endif /* if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0) */ #else /* *---------------------------------------------------------------------- @@ -933,8 +927,11 @@ HgfsRead(struct file *file, // IN: File to read from LOG(4, (KERN_DEBUG "VMware hgfs: HgfsRead: invalid dentry\n")); goto out; } - +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 16, 0) + result = new_sync_read(file, buf, count, offset); +#else result = generic_file_read(file, buf, count, offset); +#endif out: return result; } @@ -985,7 +982,11 @@ HgfsWrite(struct file *file, // IN: File to write to goto out; } +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 16, 0) + result = new_sync_write(file, buf, count, offset); +#else result = generic_file_write(file, buf, count, offset); +#endif out: return result; } -- 2.0.4 ++++++ open-vm-tools-9.4.0-1280544.tar.gz -> open-vm-tools-9.4.6-1770165.tar.gz ++++++ ++++ 188833 lines of diff (skipped) ++++++ open-vm-tools-linux-3.17.7.patch ++++++ Index: open-vm-tools-9.4.6-1770165/modules/linux/vmhgfs/inode.c =================================================================== --- open-vm-tools-9.4.6-1770165.orig/modules/linux/vmhgfs/inode.c +++ open-vm-tools-9.4.6-1770165/modules/linux/vmhgfs/inode.c @@ -1900,7 +1900,11 @@ HgfsPermission(struct inode *inode, p, #endif &inode->i_dentry, - d_alias) { +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 17, 7) + d_alias) { +#else + d_u.d_alias) { +#endif int dcount = compat_d_count(dentry); if (dcount) { LOG(4, ("Found %s %d \n", dentry->d_name.name, dcount)); ++++++ open-vm-tools-linux-3.17.patch ++++++ Index: open-vm-tools-9.4.6-1770165/modules/linux/vmhgfs/page.c =================================================================== --- open-vm-tools-9.4.6-1770165.orig/modules/linux/vmhgfs/page.c +++ open-vm-tools-9.4.6-1770165/modules/linux/vmhgfs/page.c @@ -1385,7 +1385,9 @@ HgfsWbRequestWait(HgfsWbPage *req) // I #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 13) return wait_on_bit(&req->wb_flags, PG_BUSY, +# if LINUX_VERSION_CODE < KERNEL_VERSION(3, 17, 0) HgfsWbRequestWaitUninterruptible, +# endif TASK_UNINTERRUPTIBLE); #else wait_event(req->wb_queue, ++++++ open-vm-tools-linux-3.18.0.patch ++++++ Index: open-vm-tools-9.4.6-1770165/modules/linux/vmhgfs/page.c =================================================================== --- open-vm-tools-9.4.6-1770165.orig/modules/linux/vmhgfs/page.c +++ open-vm-tools-9.4.6-1770165/modules/linux/vmhgfs/page.c @@ -1444,9 +1444,18 @@ HgfsWbRequestUnlock(HgfsWbPage *req) // LOG(6, (KERN_WARNING "VMware Hgfs: HgfsWbRequestUnlock: Invalid unlock attempted\n")); return; } +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 18, 0) smp_mb__before_clear_bit(); +#else + smp_mb__before_atomic(); +#endif clear_bit(PG_BUSY, &req->wb_flags); +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 18, 0) smp_mb__after_clear_bit(); +#else + smp_mb__after_atomic(); +#endif + #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 13) wake_up_bit(&req->wb_flags, PG_BUSY); #else ++++++ pre_checkin.sh ++++++ #!/bin/bash NAME=open-vm-tools NAMEKMP=open-vm-tools-KMP sed "s:%define.*KMP.*0:%define KMP 1:" ${NAME}.spec > ${NAMEKMP}.spec sed -i "s/\(Name:.*\)${NAME}/\1${NAMEKMP}/" ${NAMEKMP}.spec cp ${NAME}.changes ${NAMEKMP}.changes ++++++ vmware-user-autostart-wrapper ++++++ --- /var/tmp/diff_new_pack.X0XYFX/_old 2015-01-06 09:07:24.000000000 +0100 +++ /var/tmp/diff_new_pack.X0XYFX/_new 2015-01-06 09:07:24.000000000 +0100 @@ -6,7 +6,7 @@ unset SESSION_MANAGER # If running systemd, skip the delay loop as starting vmblock-fuse is not enforced -if ! (file /sbin/init | grep "systemd" &>/dev/null); then +if file /sbin/init | grep -qv "systemd"; then while [ $RETRY -lt $MAX_RETRY ]; do @@ -15,8 +15,8 @@ else logger "Try $RETRY/$MAX_RETRY : /var/run/vmblock-fuse/dev not available. sleeping for $SLEEP seconds" sleep $SLEEP - RETRY=$[ $RETRY + 1 ] - SLEEP=$[ $SLEEP * 2 ] + RETRY=$(($RETRY + 1)) + SLEEP=$(($SLEEP * 2)) fi done fi -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org