Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- dtorkin@ubuntu1:~/Desktop/practice$ make
- Compiling uvm/uvm_main.c...
- gcc -Wall -Wextra -g -Iprotocol -Iio -Isvm -Iuvm -Iconfig -Iutils -pthread -c -o uvm/uvm_main.o uvm/uvm_main.c
- uvm/uvm_main.c: In function ‘main’:
- uvm/uvm_main.c:388:12: error: redeclaration of ‘request’ with no linkage
- 388 | UvmRequest request; // Для формирования запросов
- | ^~~~~~~
- uvm/uvm_main.c:348:16: note: previous declaration of ‘request’ with type ‘UvmRequest’
- 348 | UvmRequest request;
- | ^~~~~~~
- uvm/uvm_main.c:409:37: error: ‘MAX_SVM_CONFIGS’ undeclared (first use in this function)
- 409 | if (svm_id >= 0 && svm_id < MAX_SVM_CONFIGS) {
- | ^~~~~~~~~~~~~~~
- uvm/uvm_main.c:409:37: note: each undeclared identifier is reported only once for each function it appears in
- uvm/uvm_main.c:486:59: error: request for member ‘init_channel_sent’ in something not a structure or union
- 486 | recv_msg_num, svm_id, link->init_channel_sent, link->confirm_init_received);
- | ^~
- uvm/uvm_main.c:486:84: error: request for member ‘confirm_init_received’ in something not a structure or union
- 486 | recv_msg_num, svm_id, link->init_channel_sent, link->confirm_init_received);
- | ^~
- uvm/uvm_main.c:492:18: error: ‘msg’ undeclared (first use in this function)
- 492 | else if (msg->header.message_type == MESSAGE_TYPE_PODTVERZHDENIE_KONTROLYA) {
- | ^~~
- uvm/uvm_main.c:495:17: error: ‘svm_id’ undeclared (first use in this function)
- 495 | if (svm_id >= 0 && svm_id < MAX_SVM_CONFIGS) {
- | ^~~~~~
- uvm/uvm_main.c:499:101: error: ‘recv_msg_num’ undeclared (first use in this function)
- 499 | : 'Podtverzhdenie Kontrolya' (SVM Num %u) OK for SVM ID %d.\n", recv_msg_num, svm_id);
- | ^~~~~~~~~~~~
- uvm/uvm_main.c:392:10: warning: variable ‘activity_in_iteration’ set but not used [-Wunused-but-set-variable]
- 392 | bool activity_in_iteration = false; // Был ли какой-то обмен или действие
- | ^~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:548:13: error: ‘activity_in_iteration’ undeclared (first use in this function)
- 548 | activity_in_iteration = true; // Будет действие отправки
- | ^~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:550:48: error: ‘msg_counters’ undeclared (first use in this function); did you mean ‘msg_num_counter’?
- 550 | uint16_t current_msg_num_for_svm = msg_counters[i]; // Берем счетчик для этого SVM
- | ^~~~~~~~~~~~
- | msg_num_counter
- uvm/uvm_main.c:629:13: error: ‘message_received_in_this_iteration’ undeclared (first use in this function)
- 629 | if(!message_received_in_this_iteration && uvm_keep_running){
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:334:5: error: label ‘cleanup_connections’ used but not defined
- 334 | if (pthread_create(&sender_tid, NULL, uvm_sender_thread_func, NULL) != 0) { /*...*/ goto cleanup_connections; }
- | ^~
- uvm/uvm_main.c:329:5: error: label ‘cleanup_queues’ used but not defined
- 329 | if (active_svm_count == 0) { /*...*/ goto cleanup_queues; }
- | ^~
- uvm/uvm_main.c:285:5: error: label ‘cleanup_mutexes’ used but not defined
- 285 | if (num_svms_to_run == 0) { /*...*/ goto cleanup_mutexes; }
- | ^~
- uvm/uvm_main.c:245:14: warning: unused parameter ‘argc’ [-Wunused-parameter]
- 245 | int main(int argc, char *argv[] __attribute__((unused)) ) { // argv пока не используется
- | ~~~~^~~~
- uvm/uvm_main.c: At top level:
- uvm/uvm_main.c:634:12: error: expected declaration specifiers or ‘...’ before string constant
- 634 | printf("UVM: Shutdown initiated by main loop exit or signal...\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:637:20: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘:’ token
- 637 | cleanup_connections: // Метка для goto, если не все потоки стартанули
- | ^
- uvm/uvm_main.c:640:5: error: expected identifier or ‘(’ before ‘if’
- 640 | if (uvm_outgoing_request_queue) {
- | ^~
- uvm/uvm_main.c:645:5: error: expected identifier or ‘(’ before ‘if’
- 645 | if (uvm_incoming_response_queue) uvq_shutdown(uvm_incoming_response_queue);
- | ^~
- uvm/uvm_main.c:647:24: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 647 | pthread_mutex_lock(&uvm_send_counter_mutex);
- | ^
- uvm/uvm_main.c:648:5: warning: data definition has no type or storage class
- 648 | uvm_outstanding_sends = 0;
- | ^~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:648:5: warning: type defaults to ‘int’ in declaration of ‘uvm_outstanding_sends’ [-Wimplicit-int]
- uvm/uvm_main.c:648:5: error: conflicting type qualifiers for ‘uvm_outstanding_sends’
- uvm/uvm_main.c:41:14: note: previous definition of ‘uvm_outstanding_sends’ with type ‘int’
- 41 | volatile int uvm_outstanding_sends = 0; // Пока не используется активно
- | ^~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:649:28: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 649 | pthread_cond_broadcast(&uvm_all_sent_cond);
- | ^
- uvm/uvm_main.c:650:26: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 650 | pthread_mutex_unlock(&uvm_send_counter_mutex);
- | ^
- uvm/uvm_main.c:652:24: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 652 | pthread_mutex_lock(&gui_socket_mutex);
- | ^
- uvm/uvm_main.c:653:5: error: expected identifier or ‘(’ before ‘if’
- 653 | if (gui_listen_fd >= 0) { int fd=gui_listen_fd; gui_listen_fd=-1; shutdown(fd, SHUT_RDWR); close(fd); }
- | ^~
- uvm/uvm_main.c:654:5: error: expected identifier or ‘(’ before ‘if’
- 654 | if (gui_client_fd >= 0) { int fd=gui_client_fd; gui_client_fd=-1; shutdown(fd, SHUT_RDWR); close(fd); }
- | ^~
- uvm/uvm_main.c:655:26: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 655 | pthread_mutex_unlock(&gui_socket_mutex);
- | ^
- uvm/uvm_main.c:657:12: error: expected declaration specifiers or ‘...’ before string constant
- 657 | printf("UVM: Closing SVM connections...\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:658:24: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 658 | pthread_mutex_lock(&uvm_links_mutex);
- | ^
- uvm/uvm_main.c:659:5: error: expected identifier or ‘(’ before ‘for’
- 659 | for(int i=0; i<num_svms_to_run; ++i) {
- | ^~~
- uvm/uvm_main.c:659:19: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘<’ token
- 659 | for(int i=0; i<num_svms_to_run; ++i) {
- | ^
- uvm/uvm_main.c:659:37: error: expected identifier or ‘(’ before ‘++’ token
- 659 | for(int i=0; i<num_svms_to_run; ++i) {
- | ^~
- uvm/uvm_main.c:664:26: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 664 | pthread_mutex_unlock(&uvm_links_mutex);
- | ^
- uvm/uvm_main.c:667:12: error: expected declaration specifiers or ‘...’ before string constant
- 667 | printf("UVM: Joining threads...\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:668:5: error: expected identifier or ‘(’ before ‘if’
- 668 | if (sender_tid != 0) pthread_join(sender_tid, NULL);
- | ^~
- uvm/uvm_main.c:669:12: error: expected declaration specifiers or ‘...’ before string constant
- 669 | printf("UVM: Sender thread joined.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:670:5: error: expected identifier or ‘(’ before ‘for’
- 670 | for (int i = 0; i < num_svms_to_run; ++i) {
- | ^~~
- uvm/uvm_main.c:670:23: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘<’ token
- 670 | for (int i = 0; i < num_svms_to_run; ++i) {
- | ^
- uvm/uvm_main.c:670:42: error: expected identifier or ‘(’ before ‘++’ token
- 670 | for (int i = 0; i < num_svms_to_run; ++i) {
- | ^~
- uvm/uvm_main.c:675:12: error: expected declaration specifiers or ‘...’ before string constant
- 675 | printf("UVM: All receiver threads joined.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:676:5: error: expected identifier or ‘(’ before ‘if’
- 676 | if (gui_server_tid != 0) pthread_join(gui_server_tid, NULL);
- | ^~
- uvm/uvm_main.c:677:12: error: expected declaration specifiers or ‘...’ before string constant
- 677 | printf("UVM: GUI server thread joined.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:680:24: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 680 | pthread_mutex_lock(&uvm_links_mutex);
- | ^
- uvm/uvm_main.c:681:5: error: expected identifier or ‘(’ before ‘for’
- 681 | for (int i = 0; i < MAX_SVM_INSTANCES; ++i) {
- | ^~~
- uvm/uvm_main.c:681:23: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘<’ token
- 681 | for (int i = 0; i < MAX_SVM_INSTANCES; ++i) {
- | ^
- uvm/uvm_main.c:681:44: error: expected identifier or ‘(’ before ‘++’ token
- 681 | for (int i = 0; i < MAX_SVM_INSTANCES; ++i) {
- | ^~
- uvm/uvm_main.c:690:26: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 690 | pthread_mutex_unlock(&uvm_links_mutex);
- | ^
- uvm/uvm_main.c:691:12: error: expected declaration specifiers or ‘...’ before string constant
- 691 | printf("UVM: Connections and IO interfaces cleaned up.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:693:15: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘:’ token
- 693 | cleanup_queues:
- | ^
- uvm/uvm_main.c:695:5: error: expected identifier or ‘(’ before ‘if’
- 695 | if (uvm_incoming_response_queue) uvq_destroy(uvm_incoming_response_queue);
- | ^~
- uvm/uvm_main.c:696:12: error: expected declaration specifiers or ‘...’ before string constant
- 696 | printf("UVM: Queues destroyed.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:698:16: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘:’ token
- 698 | cleanup_mutexes:
- | ^
- uvm/uvm_main.c:700:27: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 700 | pthread_mutex_destroy(&gui_socket_mutex);
- | ^
- uvm/uvm_main.c:701:27: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 701 | pthread_mutex_destroy(&uvm_send_counter_mutex);
- | ^
- uvm/uvm_main.c:702:26: error: expected declaration specifiers or ‘...’ before ‘&’ token
- 702 | pthread_cond_destroy(&uvm_all_sent_cond);
- | ^
- uvm/uvm_main.c:703:12: error: expected declaration specifiers or ‘...’ before string constant
- 703 | printf("UVM: Mutexes and condvar destroyed.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:705:12: error: expected declaration specifiers or ‘...’ before string constant
- 705 | printf("UVM Application finished.\n");
- | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- uvm/uvm_main.c:706:5: error: expected identifier or ‘(’ before ‘return’
- 706 | return 0;
- | ^~~~~~
- uvm/uvm_main.c:707:1: error: expected identifier or ‘(’ before ‘}’ token
- 707 | }
- | ^
- make: *** [Makefile:43: uvm/uvm_main.o] Ошибка 1
Advertisement
Add Comment
Please, Sign In to add comment