mirror of
https://github.com/zdharma-continuum/zconvey.git
synced 2026-09-10 07:06:21 -04:00
plugin.zsh,myflock/c.h: Support Cygwin
This commit is contained in:
parent
6df790888a
commit
627e8aff06
|
|
@ -210,8 +210,10 @@ static inline __attribute__((const)) int is_power_of_2(unsigned long num)
|
|||
}
|
||||
|
||||
#ifndef HAVE_LOFF_T
|
||||
#ifndef __CYGWIN__
|
||||
typedef int64_t loff_t;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if !defined(HAVE_DIRFD) && (!defined(HAVE_DECL_DIRFD) || HAVE_DECL_DIRFD == 0) && defined(HAVE_DIR_DD_FD)
|
||||
#include <sys/types.h>
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ function zc-id() {
|
|||
# flock in Zsh ver. < 5.3 doesn't) - util-linux/flock stripped
|
||||
# of some things, compiles hopefully everywhere (tested on OS X,
|
||||
# Linux, FreeBSD).
|
||||
if [[ ! -e "${ZCONVEY_REPO_DIR}/myflock/flock" ]]; then
|
||||
if [[ ! -e "${ZCONVEY_REPO_DIR}/myflock/flock" && ! -e "${ZCONVEY_REPO_DIR}/myflock/flock.exe" ]]; then
|
||||
(
|
||||
if zmodload zsh/system 2>/dev/null; then
|
||||
if zsystem flock -t 1 "${ZCONVEY_REPO_DIR}/myflock/LICENSE"; then
|
||||
|
|
|
|||
Loading…
Reference in a new issue