Bug 86345 - "We need touch with -h option support" but we don't use $(TOUCH)
Summary: "We need touch with -h option support" but we don't use $(TOUCH)
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Libreoffice (show other bugs)
Version: 4.3.2.2 release
Hardware: Other Solaris
: medium enhancement
Assignee: Not Assigned
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-16 17:21 UTC by Richard PALO
Modified: 2014-12-26 16:53 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Richard PALO 2014-11-16 17:21:22 UTC
In configure.ac the following:
dnl ===================================================================
dnl We need touch with -h option support.
dnl ===================================================================
AC_PATH_PROG(TOUCH, touch)
test -z "$TOUCH" && AC_MSG_ERROR([touch is required])
touch warn
if ! "$TOUCH" -h warn 2>/dev/null > /dev/null; then
    AC_MSG_ERROR([touch version with -h option support is required to build, please install it and make sure it is the one found first in PATH],,)
fi

great, for gnu platforms, but many Unix distros put gnu coreutils in, for example, /usr/gnu/bin and symlink (in this case) 
/usr/bin/gtouch ==> /usr/gnu/bin/touch

The only place this seems to be used at the moment is in solenv/gbuild/Deliver.mk
but here, as in many places (though not all).  So this patch initially created by pkgsrc developer Ryo ONODERA and updated by me seems to allow the special 'touch' ;-).    BTW, up til now, replace '-hr' by simply '-r' has seemed to work.

========================>8==================================================
--- solenv/gbuild/Deliver.mk.orig	2014-04-30 19:49:45.000000000 +0000
+++ solenv/gbuild/Deliver.mk
@@ -51,7 +51,7 @@ endif
 endef
 
 define gb_Deliver__deliver
-$(if $(gb_Deliver_CLEARONDELIVER),rm -f $(2) &&) $(if $(gb_Deliver_HARDLINK),ln,cp -P -f) $(1) $(2) && touch -hr $(1) $(2)
+$(if $(gb_Deliver_CLEARONDELIVER),rm -f $(2) &&) $(if $(gb_Deliver_HARDLINK),ln,cp -P -f) $(1) $(2) && $(TOUCH) -hr $(1) $(2)
 endef
 
 ifneq ($(strip $(gb_Deliver_GNUCOPY)),)
========================>8==================================================

by the way, it would be nice for us bearded folks who don't habitually put /usr/gnu/bin into our PATH to allow a configure option like for '--with-gnu-cp' or '--with-gnu-patch'... '--with-gnu-touch' seems appropriate *IFF* this single use of 'touch' is really necessary!
Comment 1 Robinson Tryon (qubit) 2014-11-21 22:09:32 UTC
(In reply to Richard PALO from comment #0)
> So this patch initially
> created by pkgsrc developer Ryo ONODERA and updated by me seems to allow the
> special 'touch' ;-).    BTW, up til now, replace '-hr' by simply '-r' has
> seemed to work.

Hi Richard,
I had a quick chat with our Release Engineer, and he suggested that you submit another patch to gerrit.

I'm going to mark this as an enhancement and set it to NEW. Please resolve/close it when the underlying issue you raised has been addressed.

Thanks,
--R
Comment 2 Richard PALO 2014-12-26 16:53:55 UTC
this apparently slipped by without notice, sorry:
https://gerrit.libreoffice.org/13664


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.