depends: add utf8proc

This commit is contained in:
tobtoht 2023-10-10 14:56:22 +02:00
parent cdc31c5929
commit f1d5a63c84
No known key found for this signature in database
GPG key ID: E45B10DD027D2472
2 changed files with 54 additions and 0 deletions

View file

@ -0,0 +1,28 @@
package=utf8proc
$(package)_version=2.8.0
$(package)_download_path=https://github.com/JuliaStrings/utf8proc/archive/refs/tags/
$(package)_download_file=v$($(package)_version).tar.gz
$(package)_file_name=$(package)-$($(package)_version).tar.gz
$(package)_sha256_hash=a0a60a79fe6f6d54e7d411facbfcc867a6e198608f2cd992490e46f04b1bcecc
$(package)_patches=force_static.patch
define $(package)_preprocess_cmds
patch -p1 < $($(package)_patch_dir)/force_static.patch
endef
define $(package)_config_cmds
echo "$($(package)_cmake)" && \
mkdir build && \
cd build && \
$($(package)_cmake) ..
endef
define $(package)_build_cmds
cd build && \
$(MAKE)
endef
define $(package)_stage_cmds
cd build && \
$(MAKE) DESTDIR=$($(package)_staging_dir) install
endef

View file

@ -0,0 +1,26 @@
diff --git a/utf8proc.h b/utf8proc.h
index 7ec591d..024343b 100644
--- a/utf8proc.h
+++ b/utf8proc.h
@@ -120,21 +120,7 @@ typedef bool utf8proc_bool;
#endif
#include <limits.h>
-#ifdef UTF8PROC_STATIC
# define UTF8PROC_DLLEXPORT
-#else
-# ifdef _WIN32
-# ifdef UTF8PROC_EXPORTS
-# define UTF8PROC_DLLEXPORT __declspec(dllexport)
-# else
-# define UTF8PROC_DLLEXPORT __declspec(dllimport)
-# endif
-# elif __GNUC__ >= 4
-# define UTF8PROC_DLLEXPORT __attribute__ ((visibility("default")))
-# else
-# define UTF8PROC_DLLEXPORT
-# endif
-#endif
#ifdef __cplusplus
extern "C" {