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

MSVC: Fix generation of clsocket.lib #17

Merged
merged 2 commits into from
Aug 8, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/ActiveSocket.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class CPassiveSocket;
/// An active socket is used to create a socket which connects to a server.
/// This type of object would be used when an application needs to send/receive
/// data from a server.
class CActiveSocket : public CSimpleSocket {
class EXPORT CActiveSocket : public CSimpleSocket {
public:
friend class CPassiveSocket;

Expand Down
6 changes: 6 additions & 0 deletions src/Host.h
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,12 @@ extern "C"
#define FPRINTF fprintf
#endif

#ifdef _MSC_VER
#define EXPORT __declspec(dllexport)
#else
#define EXPORT
#endif

#ifdef __cplusplus
}
#endif
Expand Down
2 changes: 1 addition & 1 deletion src/PassiveSocket.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
/// in a similar fashion. The big difference is that the method
/// CPassiveSocket::Accept should not be called on the latter two socket
/// types.
class CPassiveSocket : public CSimpleSocket {
class EXPORT CPassiveSocket : public CSimpleSocket {
public:
CPassiveSocket(CSocketType type = SocketTypeTcp);
virtual ~CPassiveSocket() {
Expand Down
2 changes: 1 addition & 1 deletion src/SimpleSocket.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
/// - Socket types
/// -# CActiveSocket Class
/// -# CPassiveSocket Class
class CSimpleSocket {
class EXPORT CSimpleSocket {
public:
/// Defines the three possible states for shuting down a socket.
typedef enum
Expand Down
2 changes: 1 addition & 1 deletion src/StatTimer.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@

/// Class to abstract socket communications in a cross platform manner.
/// This class is designed
class CStatTimer {
class EXPORT CStatTimer {
public:
CStatTimer()
{
Expand Down