Skip to content

Commit

Permalink
dlfcn-win32: add
Browse files Browse the repository at this point in the history
Signed-off-by: Rosen Penev <[email protected]>
  • Loading branch information
neheb authored and jpakkane committed Dec 29, 2022
1 parent 76ea214 commit 84f0f21
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 0 deletions.
7 changes: 7 additions & 0 deletions ci_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,13 @@
"windows": false
}
},
"dlfcn-win32": {
"_comment": "- Requires Windows",
"build_on": {
"darwin": false,
"linux": false
}
},
"epoxy": {
"debian_packages": [
"libgl-dev",
Expand Down
8 changes: 8 additions & 0 deletions releases.json
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,14 @@
"2.2.0-1"
]
},
"dlfcn-win32": {
"dependency_names": [
"dl"
],
"versions": [
"1.3.1-1"
]
},
"docopt": {
"dependency_names": [
"docopt"
Expand Down
9 changes: 9 additions & 0 deletions subprojects/dlfcn-win32.wrap
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[wrap-file]
directory = dlfcn-win32-1.3.1
source_url = https://github.com/dlfcn-win32/dlfcn-win32/archive/refs/tags/v1.3.1.tar.gz
source_filename = dlfcn-win32-1.3.1.tar.gz
source_hash = f7248a8baeb79d9bcd5f702cc08a777431708758e70d1730b59674c5e795e88a
patch_directory = dlfcn-win32

[provide]
dl = dlfcn_win32_dep
29 changes: 29 additions & 0 deletions subprojects/packagefiles/dlfcn-win32/meson.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
project(
'dlfcn-win32',
'c',
version: '1.3.1',
meson_version: '>=0.49.0',
)

if host_machine.system() != 'windows'
error('dlfcn-win32 is only for Windows. All else is unsupported.')
endif

cargs = []
if get_option('default_library') != 'static'
cargs += '-DDLFCN_WIN32_SHARED'
endif

incdirs = include_directories('src')

dlfcn = library(
'dl',
'src/dlfcn.c',
include_directories: incdirs,
c_args: cargs,
)

dlfcn_win32_dep = declare_dependency(
include_directories: incdirs,
link_with: dlfcn,
)

0 comments on commit 84f0f21

Please sign in to comment.