Jump to content
  • 0

make: *** [Makefile:41: common] Error 2


Ahoy

Question


  • Group:  Members
  • Topic Count:  16
  • Topics Per Day:  0.00
  • Content Count:  61
  • Reputation:   4
  • Joined:  12/29/14
  • Last Seen:  

Hello ,

 

want to ask , i got this error 

make[1]: *** [Makefile:65: obj/socket.o] Error 1
make[1]: Leaving directory '/home/Server/rAthena/src/common'
make: *** [Makefile:41: common] Error 2

 

im using cygwin and already using GCC ver 7.4.0

command i use :

make clean

make sql

 

and get that error , please help , thanks ?

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  42
  • Topics Per Day:  0.01
  • Content Count:  1096
  • Reputation:   344
  • Joined:  02/26/12
  • Last Seen:  

Are you trying to compile rAthena source code with cygwin under windows, right? 
You can't, there are a lot of problems. Check my work here: 

My goal was to make a compiler to my another project posted on the forum for newbies, to have a portable compiler, but I got stuck (I did solved the problem for different emulators, but not for the rAthena).
The problem with the emulator code itself.
Yes, you can fix a lot of problems with cygwin, but at a final point you will be stuck with the code itself.

I even tried to rewrite broken parts of the code, or windows / linux specific commands, dozens of warnings, etc on my own just to make it work, but even me, after around a week with tests and attempts - give up on it (again, with other emulators cygwin works fine).

So, if you want to compile the rAthena emulator try to use MS Build Tools, or ideally visual studio. 

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  16
  • Topics Per Day:  0.00
  • Content Count:  61
  • Reputation:   4
  • Joined:  12/29/14
  • Last Seen:  

complete error massage

socket.cpp:220:2: error: ‘fd_set’ does not name a type; did you mean ‘fpos_t’?
  fd_set readfds;
  ^~~~~~
  fpos_t
socket.cpp: In function ‘int connect_client(int)’:
socket.cpp:505:14: error: ‘readfds’ was not declared in this scope
  sFD_SET(fd,&readfds);
              ^~~~~~~
socket.cpp:505:14: note: suggested alternative: ‘read’
  sFD_SET(fd,&readfds);
              ^~~~~~~
              read
socket.cpp:205:17: error: ‘FD_SET’ was not declared in this scope
 #define sFD_SET FD_SET
                 ^
socket.cpp:505:2: note: in expansion of macro ‘sFD_SET’
  sFD_SET(fd,&readfds);
  ^~~~~~~
socket.cpp:205:17: note: suggested alternative: ‘sFD_SET’
 #define sFD_SET FD_SET
                 ^
socket.cpp:505:2: note: in expansion of macro ‘sFD_SET’
  sFD_SET(fd,&readfds);
  ^~~~~~~
socket.cpp: In function ‘int make_listen_bind(uint32, uint16)’:
socket.cpp:572:15: error: ‘readfds’ was not declared in this scope
  sFD_SET(fd, &readfds);
               ^~~~~~~
socket.cpp:572:15: note: suggested alternative: ‘read’
  sFD_SET(fd, &readfds);
               ^~~~~~~
               read
socket.cpp:205:17: error: ‘FD_SET’ was not declared in this scope
 #define sFD_SET FD_SET
                 ^
socket.cpp:572:2: note: in expansion of macro ‘sFD_SET’
  sFD_SET(fd, &readfds);
  ^~~~~~~
socket.cpp:205:17: note: suggested alternative: ‘sFD_SET’
 #define sFD_SET FD_SET
                 ^
socket.cpp:572:2: note: in expansion of macro ‘sFD_SET’
  sFD_SET(fd, &readfds);
  ^~~~~~~
socket.cpp: In function ‘int make_connection(uint32, uint16, bool, int)’:
socket.cpp:698:14: error: ‘readfds’ was not declared in this scope
  sFD_SET(fd,&readfds);
              ^~~~~~~
socket.cpp:698:14: note: suggested alternative: ‘read’
  sFD_SET(fd,&readfds);
              ^~~~~~~
              read
socket.cpp:205:17: error: ‘FD_SET’ was not declared in this scope
 #define sFD_SET FD_SET
                 ^
socket.cpp:698:2: note: in expansion of macro ‘sFD_SET’
  sFD_SET(fd,&readfds);
  ^~~~~~~
socket.cpp:205:17: note: suggested alternative: ‘sFD_SET’
 #define sFD_SET FD_SET
                 ^
socket.cpp:698:2: note: in expansion of macro ‘sFD_SET’
  sFD_SET(fd,&readfds);
  ^~~~~~~
socket.cpp: In function ‘int do_sockets(t_tick)’:
socket.cpp:889:2: error: ‘fd_set’ was not declared in this scope
  fd_set rfd;
  ^~~~~~
socket.cpp:889:2: note: suggested alternative: ‘fpos_t’
  fd_set rfd;
  ^~~~~~
  fpos_t
socket.cpp:916:10: error: ‘rfd’ was not declared in this scope
  memcpy(&rfd, &readfds, sizeof(rfd));
          ^~~
socket.cpp:916:16: error: ‘readfds’ was not declared in this scope
  memcpy(&rfd, &readfds, sizeof(rfd));
                ^~~~~~~
socket.cpp:916:16: note: suggested alternative: ‘read’
  memcpy(&rfd, &readfds, sizeof(rfd));
                ^~~~~~~
                read
socket.cpp:201:17: error: ‘select’ was not declared in this scope
 #define sSelect select
                 ^
socket.cpp:917:8: note: in expansion of macro ‘sSelect’
  ret = sSelect(fd_max, &rfd, NULL, NULL, &timeout);
        ^~~~~~~
socket.cpp:201:17: note: suggested alternative: ‘sSelect’
 #define sSelect select
                 ^
socket.cpp:917:8: note: in expansion of macro ‘sSelect’
  ret = sSelect(fd_max, &rfd, NULL, NULL, &timeout);
        ^~~~~~~
socket.cpp:207:19: error: ‘FD_ISSET’ was not declared in this scope
 #define sFD_ISSET FD_ISSET
                   ^
socket.cpp:977:6: note: in expansion of macro ‘sFD_ISSET’
   if(sFD_ISSET(i,&rfd) && session)
      ^~~~~~~~~
socket.cpp:207:19: note: suggested alternative: ‘sFD_ISSET’
 #define sFD_ISSET FD_ISSET
                   ^
socket.cpp:977:6: note: in expansion of macro ‘sFD_ISSET’
   if(sFD_ISSET(i,&rfd) && session)
      ^~~~~~~~~
In file included from socket.hpp:19:0,
                 from socket.cpp:4:
socket.cpp: In function ‘int socket_config_read(const char*)’:
cbasetypes.hpp:241:20: error: ‘strcasecmp’ was not declared in this scope
 #define strcmpi    strcasecmp
                    ^
socket.cpp:1308:8: note: in expansion of macro ‘strcmpi’
   if (!strcmpi(w1, "stall_time")) {
        ^~~~~~~
cbasetypes.hpp:241:20: note: suggested alternative: ‘strncmp’
 #define strcmpi    strcasecmp
                    ^
socket.cpp:1308:8: note: in expansion of macro ‘strcmpi’
   if (!strcmpi(w1, "stall_time")) {
        ^~~~~~~
socket.cpp: In function ‘void do_close(int)’:
socket.cpp:1427:15: error: ‘readfds’ was not declared in this scope
  sFD_CLR(fd, &readfds);// this needs to be done before closing the socket
               ^~~~~~~
socket.cpp:1427:15: note: suggested alternative: ‘read’
  sFD_CLR(fd, &readfds);// this needs to be done before closing the socket
               ^~~~~~~
               read
socket.cpp:206:17: error: ‘FD_CLR’ was not declared in this scope
 #define sFD_CLR FD_CLR
                 ^
socket.cpp:1427:2: note: in expansion of macro ‘sFD_CLR’
  sFD_CLR(fd, &readfds);// this needs to be done before closing the socket
  ^~~~~~~
socket.cpp:206:17: note: suggested alternative: ‘sFD_CLR’
 #define sFD_CLR FD_CLR
                 ^
socket.cpp:1427:2: note: in expansion of macro ‘sFD_CLR’
  sFD_CLR(fd, &readfds);// this needs to be done before closing the socket
  ^~~~~~~
socket.cpp: In function ‘int socket_getips(uint32*, int)’:
socket.cpp:1481:3: error: ‘u_long’ was not declared in this scope
   u_long ad;
   ^~~~~~
socket.cpp:1481:3: note: suggested alternative: ‘__Long’
   u_long ad;
   ^~~~~~
   __Long
socket.cpp:1504:6: error: ‘ad’ was not declared in this scope
      ad = ntohl(a->sin_addr.s_addr);
      ^~
socket.cpp:1504:6: note: suggested alternative: ‘a’
      ad = ntohl(a->sin_addr.s_addr);
      ^~
      a
socket.cpp: In function ‘void socket_init()’:
socket.cpp:1581:12: error: ‘readfds’ was not declared in this scope
  sFD_ZERO(&readfds);
            ^~~~~~~
socket.cpp:1581:12: note: suggested alternative: ‘read’
  sFD_ZERO(&readfds);
            ^~~~~~~
            read
socket.cpp:208:18: error: ‘FD_ZERO’ was not declared in this scope
 #define sFD_ZERO FD_ZERO
                  ^
socket.cpp:1581:2: note: in expansion of macro ‘sFD_ZERO’
  sFD_ZERO(&readfds);
  ^~~~~~~~
socket.cpp:208:18: note: suggested alternative: ‘sFD_ZERO’
 #define sFD_ZERO FD_ZERO
                  ^
socket.cpp:1581:2: note: in expansion of macro ‘sFD_ZERO’
  sFD_ZERO(&readfds);
  ^~~~~~~~
 

 

Edited by Emistry
Please use codebox.
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  16
  • Topics Per Day:  0.00
  • Content Count:  61
  • Reputation:   4
  • Joined:  12/29/14
  • Last Seen:  

2 hours ago, anacondaq said:

Are you trying to compile rAthena source code with cygwin under windows, right? 
You can't, there are a lot of problems. Check my work here: 

My goal was to make a compiler to my another project posted on the forum for newbies, to have a portable compiler, but I got stuck (I did solved the problem for different emulators, but not for the rAthena).
The problem with the emulator code itself.
Yes, you can fix a lot of problems with cygwin, but at a final point you will be stuck with the code itself.

I even tried to rewrite broken parts of the code, or windows / linux specific commands, dozens of warnings, etc on my own just to make it work, but even me, after around a week with tests and attempts - give up on it (again, with other emulators cygwin works fine).

So, if you want to compile the rAthena emulator try to use MS Build Tools, or ideally visual studio. 

 

yes, i try to compile rAthena source with cygwin on windows , because i cannot use MS Build Tools or Visual Studio...

so i just download https://www.microsoft.com/en-us/download/details.aspx?id=48159 this right ?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...