1
0
Fork 0

done done

This commit is contained in:
dtb 2023-12-21 14:56:36 -07:00
parent 45e509186d
commit 6b8ce7d5b1
2 changed files with 4 additions and 3 deletions

View File

@ -1,4 +1,4 @@
scrut: scrut.o libscrut.o
scrut: scrut.o libfileis.o
$(CC) $(CFLAGS) -o scrut scrut.o scrut.o
clean:

View File

@ -1,4 +1,5 @@
#include "libscrut.h"
#include "libfileis.h"
#include <unistd.h> /* access(3), F_OK, R_OK, W_OK, X_OK */
int f_executable(char *path){ return access(path, X_OK) == 0; } /* test -x */
@ -8,7 +9,7 @@ int f_writeable(char *path){ return access(path, W_OK) == 0; } /* test -w */
#include <sys/stat.h> /* lstat(3), struct stat, S_ISBLK, S_ISCHR, S_ISDIR,
* S_ISFIFO, S_ISGID, S_ISREG, S_ISLNK, S_ISSOCK,
* S_ISUID */
* S_ISUID, S_ISVTX */
static struct stat buf;