adam@acer ~/O/ncursesFM> ls
Arch/ COPYING makefile ncursesFM.conf README.md TODO
Changelog inc/ ncursesfm ncursesFM.png src/
adam@acer ~/O/ncursesFM> make
libX11 support enabled.
cd src/; cc -c .c -I/usr/include/ncursesw -DLIBX11_PRESENT -std=c99
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/archiver.h:3,
from archiver.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
archiver.c:4:92: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_archive(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
archiver.c: In function ‘archiver_func’:
archiver.c:42:9: warning: implicit declaration of function ‘nftw’ [-Wimplicit-function-declaration]
nftw(tmp->name, recursive_archive, 64, FTW_MOUNT | FTW_PHYS);
^
archiver.c:42:48: error: ‘FTW_MOUNT’ undeclared (first use in this function)
nftw(tmp->name, recursive_archive, 64, FTW_MOUNT | FTW_PHYS);
^
archiver.c:42:48: note: each undeclared identifier is reported only once for each function it appears in
archiver.c:42:60: error: ‘FTW_PHYS’ undeclared (first use in this function)
nftw(tmp->name, recursive_archive, 64, FTW_MOUNT | FTW_PHYS);
^
archiver.c: At top level:
archiver.c:49:92: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_archive(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
archiver.c:49:12: error: conflicting types for ‘recursive_archive’
static int recursive_archive(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
archiver.c:4:12: note: previous declaration of ‘recursive_archive’ was here
static int recursive_archive(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
archiver.c:4:12: warning: ‘recursive_archive’ used but never defined [enabled by default]
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/archiver.h:3,
from ../inc/fm_functions.h:9,
from ../inc/bookmarks.h:1,
from bookmarks.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
bookmarks.c: In function ‘update_bookmarks_tabs’:
bookmarks.c:122:13: error: type of formal parameter 3 is incomplete
update_special_mode(num_bookmarks, i, bookmarks);
^
bookmarks.c: In function ‘show_bookmarks’:
bookmarks.c:129:9: error: type of formal parameter 2 is incomplete
show_special_tab(num_bookmarks, bookmarks, bookmarks_mode_str, bookmarks);
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/archiver.h:3,
from ../inc/fm_functions.h:9,
from fm_functions.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
fm_functions.c:11:89: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_copy(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
fm_functions.c:16:91: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_remove(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
fm_functions.c: In function ‘xdg_open’:
fm_functions.c:131:9: warning: implicit declaration of function ‘vfork’ [-Wimplicit-function-declaration]
pid = vfork();
^
fm_functions.c: In function ‘move_file’:
fm_functions.c:280:5: warning: implicit declaration of function ‘lstat’ [-Wimplicit-function-declaration]
lstat(thread_h->full_path, &file_stat_pasted);
^
fm_functions.c: In function ‘cpr’:
fm_functions.c:315:5: warning: implicit declaration of function ‘nftw’ [-Wimplicit-function-declaration]
nftw(tmp->name, recursive_copy, 64, FTW_MOUNT | FTW_PHYS);
^
fm_functions.c:315:41: error: ‘FTW_MOUNT’ undeclared (first use in this function)
nftw(tmp->name, recursive_copy, 64, FTW_MOUNT | FTW_PHYS);
^
fm_functions.c:315:41: note: each undeclared identifier is reported only once for each function it appears in
fm_functions.c:315:53: error: ‘FTW_PHYS’ undeclared (first use in this function)
nftw(tmp->name, recursive_copy, 64, FTW_MOUNT | FTW_PHYS);
^
fm_functions.c: At top level:
fm_functions.c:318:89: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_copy(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
fm_functions.c:318:12: error: conflicting types for ‘recursive_copy’
static int recursive_copy(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
fm_functions.c:11:12: note: previous declaration of ‘recursive_copy’ was here
static int recursive_copy(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
fm_functions.c:369:91: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_remove(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
fm_functions.c:369:12: error: conflicting types for ‘recursive_remove’
static int recursive_remove(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
fm_functions.c:16:12: note: previous declaration of ‘recursive_remove’ was here
static int recursive_remove(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
fm_functions.c: In function ‘rmrf’:
fm_functions.c:379:38: error: ‘FTW_DEPTH’ undeclared (first use in this function)
nftw(path, recursive_remove, 64, FTW_DEPTH | FTW_PHYS | FTW_MOUNT);
^
fm_functions.c:379:50: error: ‘FTW_PHYS’ undeclared (first use in this function)
nftw(path, recursive_remove, 64, FTW_DEPTH | FTW_PHYS | FTW_MOUNT);
^
fm_functions.c:379:61: error: ‘FTW_MOUNT’ undeclared (first use in this function)
nftw(path, recursive_remove, 64, FTW_DEPTH | FTW_PHYS | FTW_MOUNT);
^
fm_functions.c: At top level:
fm_functions.c:11:12: warning: ‘recursive_copy’ used but never defined [enabled by default]
static int recursive_copy(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
In file included from ../inc/log.h:6:0,
from log.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
log.c: In function ‘log_message’:
log.c:56:9: warning: implicit declaration of function ‘syscall’ [-Wimplicit-function-declaration]
pid = syscall(SYS_gettid);
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/archiver.h:3,
from ../inc/fm_functions.h:9,
from ../inc/bookmarks.h:1,
from main.c:24:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
main.c: In function ‘set_signals’:
main.c:83:12: error: variable ‘main_act’ has initializer but incomplete type
struct sigaction main_act = {{0}};
^
main.c:83:12: error: extra brace group at end of initializer
main.c:83:12: error: (near initialization for ‘main_act’)
main.c:83:12: warning: excess elements in struct initializer [enabled by default]
main.c:83:12: warning: (near initialization for ‘main_act’) [enabled by default]
main.c:83:22: error: storage size of ‘main_act’ isn’t known
struct sigaction main_act = {{0}};
^
main.c:87:5: warning: implicit declaration of function ‘sigaction’ [-Wimplicit-function-declaration]
sigaction(SIGINT, &main_act, 0);
^
main.c:89:5: warning: implicit declaration of function ‘sigemptyset’ [-Wimplicit-function-declaration]
sigemptyset(&mask);
^
main.c:90:5: warning: implicit declaration of function ‘sigaddset’ [-Wimplicit-function-declaration]
sigaddset(&mask, SIGINT);
^
main.c:92:5: warning: implicit declaration of function ‘sigprocmask’ [-Wimplicit-function-declaration]
sigprocmask(SIG_BLOCK, &mask, &main_mask);
^
main.c:92:17: error: ‘SIG_BLOCK’ undeclared (first use in this function)
sigprocmask(SIG_BLOCK, &mask, &main_mask);
^
main.c:92:17: note: each undeclared identifier is reported only once for each function it appears in
main.c: In function ‘sigsegv_handler’:
main.c:156:5: warning: implicit declaration of function ‘kill’ [-Wimplicit-function-declaration]
kill(getpid(), signum);
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/archiver.h:3,
from ../inc/fm_functions.h:9,
from ../inc/mount.h:1,
from mount.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/quit_functions.h:3,
from quit_functions.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
In file included from ../inc/timer.h:2:0,
from ../inc/ui_functions.h:4,
from ../inc/quit_functions.h:3,
from quit_functions.c:1:
/usr/include/i386-linux-gnu/sys/timerfd.h:38:28: error: unknown type name ‘clockid_t’
extern int timerfd_create (clockid_t __clock_id, int __flags) _THROW;
^
quit_functions.c: In function ‘quit_worker_th’:
quit_functions.c:48:5: warning: implicit declaration of function ‘pthread_kill’ [-Wimplicit-function-declaration]
if ((worker_th) && (pthread_kill(worker_th, 0) != ESRCH)) {
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/archiver.h:3,
from ../inc/fm_functions.h:9,
from ../inc/search.h:1,
from search.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
search.c:3:91: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_search(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
search.c:44:91: warning: ‘struct FTW’ declared inside parameter list [enabled by default]
static int recursive_search(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
search.c:44:12: error: conflicting types for ‘recursive_search’
static int recursive_search(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf) {
^
search.c:3:12: note: previous declaration of ‘recursive_search’ was here
static int recursive_search(const char *path, const struct stat *sb, int typeflag, struct FTW *ftwbuf);
^
search.c: In function ‘recursive_search’:
search.c:46:27: error: ‘FTW_CONTINUE’ undeclared (first use in this function)
int len, r = 0, ret = FTW_CONTINUE;
^
search.c:46:27: note: each undeclared identifier is reported only once for each function it appears in
search.c:51:15: error: dereferencing pointer to incomplete type
if (ftwbuf->level == 0) {
^
search.c:60:16: error: ‘FTW_SKIP_SUBTREE’ undeclared (first use in this function)
return FTW_SKIP_SUBTREE;
^
search.c:68:5: warning: implicit declaration of function ‘strcasestr’ [-Wimplicit-function-declaration]
} else if (strcasestr(fixed_str, sv.searched_string)) {
^
search.c:75:19: error: ‘FTW_STOP’ undeclared (first use in this function)
ret = FTW_STOP;
^
search.c: In function ‘search_inside_archive’:
search.c:88:24: error: ‘FTW_CONTINUE’ undeclared (first use in this function)
int len = 0, ret = FTW_CONTINUE, r = 0, string_length;
^
search.c:106:27: error: ‘FTW_STOP’ undeclared (first use in this function)
ret = FTW_STOP;
^
search.c: In function ‘search_thread’:
search.c:121:5: warning: implicit declaration of function ‘nftw’ [-Wimplicit-function-declaration]
nftw(ps[active].my_cwd, recursive_search, 64, FTW_MOUNT | FTW_PHYS | FTW_ACTIONRETVAL);
^
search.c:121:51: error: ‘FTW_MOUNT’ undeclared (first use in this function)
nftw(ps[active].my_cwd, recursive_search, 64, FTW_MOUNT | FTW_PHYS | FTW_ACTIONRETVAL);
^
search.c:121:63: error: ‘FTW_PHYS’ undeclared (first use in this function)
nftw(ps[active].my_cwd, recursive_search, 64, FTW_MOUNT | FTW_PHYS | FTW_ACTIONRETVAL);
^
search.c:121:74: error: ‘FTW_ACTIONRETVAL’ undeclared (first use in this function)
nftw(ps[active].my_cwd, recursive_search, 64, FTW_MOUNT | FTW_PHYS | FTW_ACTIONRETVAL);
^
search.c: In function ‘list_found’:
search.c:144:5: error: type of formal parameter 2 is incomplete
show_special_tab(sv.found_cont, sv.found_searched, str, search);
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/timer.h:1,
from timer.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
In file included from ../inc/timer.h:2:0,
from ../inc/ui_functions.h:4,
from ../inc/timer.h:1,
from timer.c:1:
/usr/include/i386-linux-gnu/sys/timerfd.h:38:28: error: unknown type name ‘clockid_t’
extern int timerfd_create (clockid_t __clock_id, int __flags) __THROW;
^
timer.c: In function ‘start_timer’:
timer.c:15:12: error: variable ‘timerValue’ has initializer but incomplete type
struct itimerspec timerValue = {{0}};
^
timer.c:15:12: error: extra brace group at end of initializer
timer.c:15:12: error: (near initialization for ‘timerValue’)
timer.c:15:12: warning: excess elements in struct initializer [enabled by default]
timer.c:15:12: warning: (near initialization for ‘timerValue’) [enabled by default]
timer.c:15:23: error: storage size of ‘timerValue’ isn’t known
struct itimerspec timerValue = {{0}};
^
timer.c:17:5: warning: implicit declaration of function ‘timerfd_create’ [-Wimplicit-function-declaration]
timerfd = timerfd_create(CLOCK_MONOTONIC, 0);
^
timer.c:17:30: error: ‘CLOCK_MONOTONIC’ undeclared (first use in this function)
timerfd = timerfd_create(CLOCK_MONOTONIC, 0);
^
timer.c:17:30: note: each undeclared identifier is reported only once for each function it appears in
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
In file included from ../inc/timer.h:2:0,
from ../inc/ui_functions.h:4,
from ui_functions.c:1:
/usr/include/i386-linux-gnu/sys/timerfd.h:38:28: error: unknown type name ‘clockid_t’
extern int timerfd_create (clockid_t __clock_id, int __flags) THROW;
^
ui_functions.c:41:5: error: ‘alphasort’ undeclared here (not in a function)
alphasort, sizesort, last_mod_sort, typesort
^
ui_functions.c: In function ‘generate_list’:
ui_functions.c:118:5: warning: implicit declaration of function ‘scandir’ [-Wimplicit-function-declaration]
ps[win].number_of_files = scandir(ps[win].my_cwd, &files, is_hidden, sorting_func[sorting_index]);
^
ui_functions.c:119:5: warning: passing argument 1 of ‘free’ discards ‘const’ qualifier from pointer target type [enabled by default]
free(ps[win].nl);
^
In file included from ../inc/ui_functions.h:9:0,
from ui_functions.c:1:
/usr/include/stdlib.h:483:13: note: expected ‘void *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern void free (void *__ptr) THROW;
^
ui_functions.c:120:5: warning: passing argument 2 of ‘calloc’ makes integer from pointer without a cast [enabled by default]
if (!(ps[win].nl = calloc(ps[win].number_of_files, PATH_MAX))) {
^
In file included from ../inc/ui_functions.h:9:0,
from ui_functions.c:1:
/usr/include/stdlib.h:468:14: note: expected ‘size_t’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern void *calloc (size_t __nmemb, size_t _size)
^
ui_functions.c:124:5: error: assignment of read-only location ‘[win]’
str_ptr[win] = ps[win].nl;
^
ui_functions.c:127:13: warning: passing argument 1 of ‘sprintf’ from incompatible pointer type [enabled by default]
sprintf(ps[win].nl[i], "%s/%s", ps[win].my_cwd, files[i]->d_name);
^
In file included from ../inc/log.h:1:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/stdio.h:364:12: note: expected ‘char * restrict’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern int sprintf (char restrict s,
^
ui_functions.c:127:13: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘int ( const)(const struct dirent *, const struct dirent *)’ [-Wformat=]
sprintf(ps[win].nl[i], "%s/%s", ps[win].my_cwd, files[i]->d_name);
^
ui_functions.c: In function ‘typesort’:
ui_functions.c:168:9: warning: implicit declaration of function ‘alphasort’ [-Wimplicit-function-declaration]
return alphasort(d1, d2);
^
ui_functions.c:170:26: error: ‘DT_DIR’ undeclared (first use in this function)
if ((d1)->d_type == DT_DIR) {
^
ui_functions.c:170:26: note: each undeclared identifier is reported only once for each function it appears in
ui_functions.c:170:23: warning: comparison between pointer and integer [enabled by default]
if ((d1)->d_type == DT_DIR) {
^
ui_functions.c:172:34: error: ‘DT_REG’ undeclared (first use in this function)
} else if (((d1)->d_type == DT_REG) && ((d2)->d_type == DT_LNK)) {
^
ui_functions.c:172:31: warning: comparison between pointer and integer [enabled by default]
} else if (((d1)->d_type == DT_REG) && ((d2)->d_type == DT_LNK)) {
^
ui_functions.c:172:63: error: ‘DT_LNK’ undeclared (first use in this function)
} else if (((d1)->d_type == DT_REG) && ((d2)->d_type == DT_LNK)) {
^
ui_functions.c:172:60: warning: comparison between pointer and integer [enabled by default]
} else if (((d1)->d_type == DT_REG) && ((d2)->d_type == DT_LNK)) {
^
ui_functions.c: In function ‘list_everything’:
ui_functions.c:211:17: warning: assignment from incompatible pointer type [enabled by default]
str = *(str_ptr[win] + i);
^
ui_functions.c:213:13: warning: passing argument 1 of ‘check_selected’ from incompatible pointer type [enabled by default]
check_selected((str_ptr[win] + i), win, i);
^
ui_functions.c:25:13: note: expected ‘const char ’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
static void check_selected(const char str, int win, int line);
^
ui_functions.c:214:13: warning: passing argument 1 of ‘strrchr’ from incompatible pointer type [enabled by default]
str = strrchr((str_ptr[win] + i), '/') + 1;
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:263:14: note: expected ‘const char ’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern char strrchr (const char *__s, int _c)
^
ui_functions.c:216:9: warning: passing argument 2 of ‘colored_folders’ from incompatible pointer type [enabled by default]
colored_folders(ps[win].mywin.fm, *(str_ptr[win] + i));
^
ui_functions.c:14:13: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
static void colored_folders(WINDOW win, const char *name);
^
ui_functions.c: In function ‘initialize_tab_cwd’:
ui_functions.c:316:5: warning: passing argument 1 of ‘strlen’ from incompatible pointer type [enabled by default]
if (strlen(config.starting_dir)) {
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:399:15: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern size_t strlen (const char *s)
^
ui_functions.c:318:13: warning: passing argument 1 of ‘strcpy’ from incompatible pointer type [enabled by default]
strcpy(ps[win].my_cwd, config.starting_dir);
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:129:14: note: expected ‘char * restrict’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern char *strcpy (char *__restrict __dest, const char *__restrict src)
^
ui_functions.c:318:13: warning: passing argument 2 of ‘strcpy’ from incompatible pointer type [enabled by default]
strcpy(ps[win].my_cwd, config.starting_dir);
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:129:14: note: expected ‘const char * restrict’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern char *strcpy (char *__restrict __dest, const char *__restrict src)
^
ui_functions.c:321:5: warning: passing argument 1 of ‘strlen’ from incompatible pointer type [enabled by default]
if (!strlen(ps[win].my_cwd)) {
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:399:15: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern size_t strlen (const char *s)
^
ui_functions.c:322:9: warning: passing argument 1 of ‘getcwd’ from incompatible pointer type [enabled by default]
getcwd(ps[win].my_cwd, PATH_MAX);
^
In file included from ../inc/log.h:2:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/unistd.h:511:14: note: expected ‘char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern char *getcwd (char *__buf, size_t __size) __THROW wur;
^
ui_functions.c:322:9: warning: passing argument 2 of ‘getcwd’ makes integer from pointer without a cast [enabled by default]
getcwd(ps[win].my_cwd, PATH_MAX);
^
In file included from ../inc/log.h:2:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/unistd.h:511:14: note: expected ‘size_t’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern char *getcwd (char *__buf, size_t __size) __THROW wur;
^
ui_functions.c:324:5: error: assignment of read-only location ‘[0]’
ps[win].old_file[0] = 0;
^
ui_functions.c:326:5: warning: passing argument 1 of ‘change_dir’ from incompatible pointer type [enabled by default]
if (change_dir(ps[win].my_cwd, win) == -1) {
^
In file included from ../inc/mount.h:1:0,
from ../inc/ui_functions.h:5,
from ui_functions.c:1:
../inc/fm_functions.h:28:5: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
int change_dir(const char *str, int win);
^
ui_functions.c: In function ‘delete_tab’:
ui_functions.c:339:5: warning: passing argument 1 of ‘memset’ discards ‘const’ qualifier from pointer target type [enabled by default]
memset(ps[win].my_cwd, 0, sizeof(ps[win].my_cwd));
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:66:14: note: expected ‘void *’ but argument is of type ‘int (_ const_)(const struct dirent *, const struct dirent *)’
extern void *memset (void *__s, int __c, size_t __n) __THROW nonnull ((1));
^
ui_functions.c:339:5: warning: passing argument 3 of ‘memset’ makes integer from pointer without a cast [enabled by default]
memset(ps[win].my_cwd, 0, sizeof(ps[win].my_cwd));
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:66:14: note: expected ‘size_t’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern void *memset (void *__s, int __c, size_t __n) __THROW nonnull ((1));
^
ui_functions.c:342:5: warning: passing argument 1 of ‘free’ discards ‘const’ qualifier from pointer target type [enabled by default]
free(ps[win].nl);
^
In file included from ../inc/ui_functions.h:9:0,
from ui_functions.c:1:
/usr/include/stdlib.h:483:13: note: expected ‘void *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern void free (void *__ptr) THROW;
^
ui_functions.c: In function ‘colored_folders’:
ui_functions.c:396:5: warning: implicit declaration of function ‘lstat’ [-Wimplicit-function-declaration]
if (lstat(name, &file_stat) == 0) {
^
ui_functions.c: In function ‘show_stat’:
ui_functions.c:525:30: error: subscripted value is pointer to function
if (stat(str_ptr[win][i], &file_stat) == -1) {
^
ui_functions.c:525:9: warning: passing argument 1 of ‘stat’ from incompatible pointer type [enabled by default]
if (stat(str_ptr[win][i], &file_stat) == -1) {
^
In file included from /usr/include/libudev.h:25:0,
from ../inc/timer.h:3,
from ../inc/ui_functions.h:4,
from ui_functions.c:1:
/usr/include/i386-linux-gnu/sys/stat.h:209:12: note: expected ‘const char * restrict’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern int stat (const char *__restrict file,
^
ui_functions.c: In function ‘main_poll’:
ui_functions.c:730:9: warning: implicit declaration of function ‘ppoll’ [-Wimplicit-function-declaration]
int r = ppoll(main_p, nfds, NULL, &main_mask);
^
ui_functions.c: In function ‘tab_refresh’:
ui_functions.c:832:9: warning: passing argument 1 of ‘strlen’ from incompatible pointer type [enabled by default]
if (strlen(ps[win].old_file)) {
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:399:15: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern size_t strlen (const char *s)
^
ui_functions.c:833:13: warning: passing argument 2 of ‘move_cursor_to_file’ from incompatible pointer type [enabled by default]
move_cursor_to_file(0, ps[win].old_file, win);
^
In file included from ../inc/mount.h:1:0,
from ../inc/ui_functions.h:5,
from ui_functions.c:1:
../inc/fm_functions.h:39:5: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
int move_cursor_to_file(int i, const char *filename, int win);
^
ui_functions.c:834:13: warning: passing argument 1 of ‘strlen’ from incompatible pointer type [enabled by default]
memset(ps[win].old_file, 0, strlen(ps[win].old_file));
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:399:15: note: expected ‘const char *’ but argument is of type ‘int (_ const_)(const struct dirent *, const struct dirent *)’
extern size_t strlen (const char *s)
^
ui_functions.c:834:13: warning: passing argument 1 of ‘memset’ discards ‘const’ qualifier from pointer target type [enabled by default]
memset(ps[win].old_file, 0, strlen(ps[win].old_file));
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:66:14: note: expected ‘void *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern void *memset (void *__s, int __c, size_t __n) __THROW __nonnull ((1));
^
ui_functions.c: At top level:
ui_functions.c:842:52: error: size of array ‘str’ has non-integer type
void update_special_mode(int num, int win, char (str)[PATH_MAX + 1]) {
^
ui_functions.c: In function ‘update_special_mode’:
ui_functions.c:847:9: error: assignment of read-only location ‘[win]’
str_ptr[win] = str;
^
ui_functions.c: At top level:
ui_functions.c:862:39: error: size of array ‘str’ has non-integer type
void show_special_tab(int num, char (str)[PATH_MAX + 1], const char *title, int mode) {
^
ui_functions.c: In function ‘show_special_tab’:
ui_functions.c:865:5: error: assignment of read-only location ‘[active]’
str_ptr[active] = str;
^
ui_functions.c:866:5: warning: passing argument 1 of ‘strcpy’ from incompatible pointer type [enabled by default]
strcpy(ps[active].title, title);
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:129:14: note: expected ‘char * restrict’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern char *strcpy (char *__restrict __dest, const char *__restrict src)
^
ui_functions.c: In function ‘highlight_selected’:
ui_functions.c:938:13: warning: passing argument 1 of ‘strcmp’ from incompatible pointer type [enabled by default]
if ((i == active) || ((!strcmp(ps[i].my_cwd, ps[active].my_cwd))
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:144:12: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern int strcmp (const char *__s1, const char *s2)
^
ui_functions.c:938:13: warning: passing argument 2 of ‘strcmp’ from incompatible pointer type [enabled by default]
if ((i == active) || ((!strcmp(ps[i].my_cwd, ps[active].my_cwd))
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:144:12: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern int strcmp (const char *__s1, const char *s2)
^
ui_functions.c: In function ‘check_selected’:
ui_functions.c:953:9: warning: passing argument 1 of ‘strcmp’ from incompatible pointer type [enabled by default]
if (!strcmp(tmp->name, str)) {
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:144:12: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern int strcmp (const char *__s1, const char *s2)
^
ui_functions.c: In function ‘trigger_fullname_win’:
ui_functions.c:1062:37: error: subscripted value is pointer to function
int len = strlen(str_ptr[active][ps[active].curr_pos]);
^
ui_functions.c:1062:5: warning: passing argument 1 of ‘strlen’ from incompatible pointer type [enabled by default]
int len = strlen(str_ptr[active][ps[active].curr_pos]);
^
In file included from ../inc/log.h:4:0,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/string.h:399:15: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
extern size_t strlen (const char *s)
^
ui_functions.c: In function ‘fullname_print’:
ui_functions.c:1069:50: error: subscripted value is pointer to function
colored_folders(fullname_win, str_ptr[active][ps[active].curr_pos]);
^
ui_functions.c:1069:5: warning: passing argument 2 of ‘colored_folders’ from incompatible pointer type [enabled by default]
colored_folders(fullname_win, str_ptr[active][ps[active].curr_pos]);
^
ui_functions.c:393:13: note: expected ‘const char *’ but argument is of type ‘int ( const)(const struct dirent *, const struct dirent *)’
static void colored_folders(WINDOW *win, const char *name) {
^
ui_functions.c:1070:50: error: subscripted value is pointer to function
mvwprintw(fullname_win, 0, 0, str_ptr[active][ps[active].curr_pos]);
^
ui_functions.c:1070:5: warning: passing argument 4 of ‘mvwprintw’ from incompatible pointer type [enabled by default]
mvwprintw(fullname_win, 0, 0, str_ptr[active][ps[active].curr_pos]);
^
In file included from ../inc/declarations.h:8:0,
from ../inc/log.h:6,
from ../inc/ui_functions.h:3,
from ui_functions.c:1:
/usr/include/ncursesw/ncurses.h:699:28: note: expected ‘const char *’ but argument is of type ‘int (_ const_)(const struct dirent *, const struct dirent *)’
extern NCURSES_EXPORT(int) mvwprintw (WINDOW_,int,int, const char ,...) / implemented /
^
In file included from ../inc/log.h:6:0,
from ../inc/ui_functions.h:3,
from ../inc/worker_thread.h:6,
from worker_thread.c:1:
../inc/declarations.h:79:17: error: ‘PATH_MAX’ undeclared here (not in a function)
char editor[PATH_MAX + 1];
^
../inc/declarations.h:135:19: error: ‘NAME_MAX’ undeclared here (not in a function)
char old_file[NAME_MAX + 1];
^
../inc/declarations.h:174:1: error: unknown type name ‘sigset_t’
sigset_t main_mask;
^
In file included from ../inc/timer.h:2:0,
from ../inc/ui_functions.h:4,
from ../inc/worker_thread.h:6,
from worker_thread.c:1:
/usr/include/i386-linux-gnu/sys/timerfd.h:38:28: error: unknown type name ‘clockid_t’
extern int timerfd_create (clockid_t __clock_id, int __flags) __THROW;
^
make: ** [objects] Błąd 1