[Slackbuilds-users] physfs 3.x breaks packages

CRTS crts at gmx.net
Thu Sep 10 21:08:42 UTC 2020


Hi,

I just had two packages break because of the new physfs 3.0.2.
The problem is that the macro '__EXPORT__' is no longer defined
the new version and must be replaced with by 'PHYSFS_DECL' by
all packages that have a dependency on 'physfs' - at least
that is how I got those packages to build.

In both cases the file 'physfswrops.h' had to be patched.
Here is a sample patch that I used, to give you an idea what
to look for when you create a patch for your Slackbuilds:

> --- physfsrwops.h.org   2020-09-10 20:53:37.210572563 +0200
> +++ physfsrwops.h       2020-09-10 20:56:15.565592853 +0200
> @@ -39,7 +39,7 @@
>   *  @return A valid SDL_RWops structure on success, NULL on error. Specifics
>   *           of the error can be gleaned from PHYSFS_getLastError().
>   */
> -__EXPORT__ SDL_RWops *PHYSFSRWOPS_openRead(const char *fname);
> +PHYSFS_DECL SDL_RWops *PHYSFSRWOPS_openRead(const char *fname);
>
>  /**
>   * Open a platform-independent filename for writing, and make it accessible
> @@ -51,7 +51,7 @@
>   *  @return A valid SDL_RWops structure on success, NULL on error. Specifics
>   *           of the error can be gleaned from PHYSFS_getLastError().
>   */
> -__EXPORT__ SDL_RWops *PHYSFSRWOPS_openWrite(const char *fname);
> +PHYSFS_DECL SDL_RWops *PHYSFSRWOPS_openWrite(const char *fname);
>
>  /**
>   * Open a platform-independent filename for appending, and make it accessible
> @@ -63,7 +63,7 @@
>   *  @return A valid SDL_RWops structure on success, NULL on error. Specifics
>   *           of the error can be gleaned from PHYSFS_getLastError().
>   */
> -__EXPORT__ SDL_RWops *PHYSFSRWOPS_openAppend(const char *fname);
> +PHYSFS_DECL SDL_RWops *PHYSFSRWOPS_openAppend(const char *fname);
>
>  /**
>   * Make a SDL_RWops from an existing PhysicsFS file handle. You should
> @@ -75,7 +75,7 @@
>   *  @return A valid SDL_RWops structure on success, NULL on error. Specifics
>   *           of the error can be gleaned from PHYSFS_getLastError().
>   */
> -__EXPORT__ SDL_RWops *PHYSFSRWOPS_makeRWops(PHYSFS_file *handle);
> +PHYSFS_DECL SDL_RWops *PHYSFSRWOPS_makeRWops(PHYSFS_file *handle);
>
>  #ifdef __cplusplus
>  }

Regards
CRTS



More information about the SlackBuilds-users mailing list