diff options
author | Einhard Leichtfuß | 2018-03-31 22:14:35 +0200 |
---|---|---|
committer | Einhard Leichtfuß | 2018-03-31 22:18:32 +0200 |
commit | eb3b65e5b788b7cadc6d14cace3377d59abc8b33 (patch) | |
tree | 29e5f076ff30b6d4f2f8a73ed2d82923984f84e7 | |
parent | dcd63e0c2142d357061d8936d3b1c5342cac97db (diff) | |
download | aur-eb3b65e5b788b7cadc6d14cace3377d59abc8b33.tar.gz |
Replace cp by install
and thereby remove the need for explicitly creating the directory to
copy the docs in, which might have been pointless in the case of no doc
existing.
Also, replace the short-circuiting using `&&' by an if-statement in
order to prevent package() from failing.
The changes do not affect the resulting package.
-rw-r--r-- | PKGBUILD | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -21,14 +21,15 @@ build() package() { - mkdir -p "${pkgdir}/usr/share/dictd" - cp ${_lang}/build/dictd/${_lang}.{dict.dz,index} \ - "${pkgdir}/usr/share/dictd/" + install -m 755 -d "${pkgdir}/usr/share/dictd" + install -m 644 -t "${pkgdir}/usr/share/dictd/" \ + ${_lang}/build/dictd/${_lang}.{dict.dz,index} - mkdir -p "${pkgdir}/usr/share/doc/freedict/${_lang}" for file in ${_lang}/{AUTHORS,README,NEWS,ChangeLog} do - test -f ${file} && \ - cp ${file} "${pkgdir}/usr/share/doc/freedict/${_lang}/" + if test -f ${file} + then + install -m 644 -Dt "${pkgdir}/usr/share/doc/freedict/${_lang}/" ${file} + fi done } |