Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compilation errors #5

Open
madeleineaaseremedios opened this issue May 2, 2024 · 0 comments
Open

compilation errors #5

madeleineaaseremedios opened this issue May 2, 2024 · 0 comments

Comments

@madeleineaaseremedios
Copy link

Hi! I encountered this error when trying to compile:

gcc -O3  -o ../anchors anchors.c skiplist.c
skiplist.c:12:37: warning: format specifies type 'unsigned int' but the argument has type 'void *' [-Wformat]
  printf("  %d   %x\n", tbp->index, tbp->myelem);
                 ~~                 ^~~~~~~~~~~
1 warning generated.
gcc -O3  -o ../chaos fchaos.c thrtrie.c skiplist.c global.c translate.c filebuffer.c -lm -DCHAOS__FLAG
fchaos.c:357:59: warning: data argument not used by format string [-Wformat-extra-args]
        fprintf(stderr, "WARNING %c converted to N\n", currchar, alpha);
                        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~            ^
1 warning generated.
In file included from thrtrie.c:13:
./mempage.c:48:1: warning: non-void function does not return a value [-Wreturn-type]
}
^
1 warning generated.
skiplist.c:12:37: warning: format specifies type 'unsigned int' but the argument has type 'void *' [-Wformat]
  printf("  %d   %x\n", tbp->index, tbp->myelem);
                 ~~                 ^~~~~~~~~~~
1 warning generated.
global.c:172:1: warning: non-void function does not return a value [-Wreturn-type]
}
^
1 warning generated.
filebuffer.c:123:34: error: call to undeclared library function 'toupper' with type 'int (int)'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
    temp[i] = (strchr (alphabet, toupper ((char) i)) != 0) ?
                                 ^
filebuffer.c:123:34: note: include the header <ctype.h> or explicitly provide a declaration for 'toupper'
1 error generated.
make[1]: *** [../chaos] Error 1
make: *** [all] Error 2

Any help would be greatly appreciated!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant