Skip to content

freerdp: add package #6933

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

Draft
wants to merge 20 commits into
base: dev
Choose a base branch
from
Draft

freerdp: add package #6933

wants to merge 20 commits into from

Conversation

star-hengxing
Copy link
Contributor

No description provided.

@luadebug
Copy link
Contributor

luadebug commented Apr 20, 2025

Is it export surface (dllimport/dllexport) issue? It feels like static symbols broke for .lib on MinGW.

@star-hengxing
Copy link
Contributor Author

star-hengxing commented Apr 21, 2025

Is it export surface (dllimport/dllexport) issue? It feels like static symbols broke for .lib on MinGW.

I've also find a similar issue on MinGW: jbaldwin/libcoro#283
We need to investigate the different effects of these function decoration:

  • __attribute__((visibility("default")))
  • __declspec((dllexport/dllimport))
  • __attribute__((dllexport/dllimport))

https://github.com/FreeRDP/FreeRDP/blob/e2e6e9fd8581b779d2accba4e054fa652a13df9e/include/freerdp/api.h

#if defined _WIN32 || defined __CYGWIN__
    #ifdef FREERDP_EXPORTS
        #ifdef __GNUC__
            #define FREERDP_API __attribute__((dllexport))
        #else
            #define FREERDP_API __declspec(dllexport)
        #endif
    #else
        #ifdef __GNUC__
            #define FREERDP_API __attribute__((dllimport))
        #else
            #define FREERDP_API __declspec(dllimport)
        #endif
    #endif
#else
    #if defined(__GNUC__) && (__GNUC__ >= 4)
        #define FREERDP_API __attribute__((visibility("default")))
    #else
        #define FREERDP_API
    #endif
#endif

@luadebug
Copy link
Contributor

Is it export surface (dllimport/dllexport) issue? It feels like static symbols broke for .lib on MinGW.

I've also find a similar issue on MinGW: jbaldwin/libcoro#283 We need to investigate the different effects of these function decoration:

* `__attribute__((visibility("default")))`

* `__declspec((dllexport/dllimport))`

* `__attribute__((dllexport/dllimport))`

https://github.com/FreeRDP/FreeRDP/blob/e2e6e9fd8581b779d2accba4e054fa652a13df9e/include/freerdp/api.h

#if defined _WIN32 || defined __CYGWIN__
    #ifdef FREERDP_EXPORTS
        #ifdef __GNUC__
            #define FREERDP_API __attribute__((dllexport))
        #else
            #define FREERDP_API __declspec(dllexport)
        #endif
    #else
        #ifdef __GNUC__
            #define FREERDP_API __attribute__((dllimport))
        #else
            #define FREERDP_API __declspec(dllimport)
        #endif
    #endif
#else
    #if defined(__GNUC__) && (__GNUC__ >= 4)
        #define FREERDP_API __attribute__((visibility("default")))
    #else
        #define FREERDP_API
    #endif
#endif

I tried to rely over existing implementation, it required to add two more syslinks. It seems passing.

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

Successfully merging this pull request may close these issues.

2 participants