Skip to content

Commit 4ed5741

Browse files
committed
Add MinGW support for sdl2-net
1 parent 039acd4 commit 4ed5741

File tree

3 files changed

+48
-2
lines changed
  • packages
    • conf-mingw-w64-sdl2-net-i686/conf-mingw-w64-sdl2-net-i686.1
    • conf-mingw-w64-sdl2-net-x86_64/conf-mingw-w64-sdl2-net-x86_64.1
    • conf-sdl2-net/conf-sdl2-net.1

3 files changed

+48
-2
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
opam-version: "2.0"
2+
synopsis: "Provides sdl2-net for i686 mingw-w64 (32-bit x86)"
3+
description: "Ensure that the i686 version of sdl2-net for the mingw-w64 project is available"
4+
maintainer: "https://github.com/ocaml/opam-repository/issues"
5+
authors: "Sam Lantinga"
6+
license: "Zlib"
7+
homepage: "http://www.libsdl.org/projects/SDL_net/"
8+
bug-reports: "https://github.com/ocaml/opam-repository/issues"
9+
flags: conf
10+
available: os = "win32"
11+
build: ["pkgconf" "--personality=i686-w64-mingw32" "SDL2_net"]
12+
depends: [
13+
"conf-pkg-config" {build}
14+
"conf-mingw-w64-gcc-i686" {build}
15+
]
16+
depexts: [
17+
["mingw64-i686-SDL2_net"] {os = "win32" & os-distribution = "cygwin"}
18+
["mingw-w64-i686-SDL2_net"] {os = "win32" & os-distribution = "msys2"}
19+
]
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
opam-version: "2.0"
2+
synopsis: "Provides sdl2-net for x86_64 mingw-w64 (64-bit x86_64)"
3+
description: "Ensure that the x86_64 version of sdl2-net for the mingw-w64 project is available"
4+
maintainer: "https://github.com/ocaml/opam-repository/issues"
5+
authors: "Sam Lantinga"
6+
license: "Zlib"
7+
homepage: "http://www.libsdl.org/projects/SDL_net/"
8+
bug-reports: "https://github.com/ocaml/opam-repository/issues"
9+
flags: conf
10+
available: os = "win32"
11+
build: ["pkgconf" "--personality=x86_64-w64-mingw32" "SDL2_net"]
12+
depends: [
13+
"conf-pkg-config" {build}
14+
"conf-mingw-w64-gcc-x86_64" {build}
15+
]
16+
depexts: [
17+
["mingw64-x86_64-SDL2_net"] {os = "win32" & os-distribution = "cygwin"}
18+
["mingw-w64-x86_64-SDL2_net"] {os = "win32" & os-distribution = "msys2"}
19+
]

packages/conf-sdl2-net/conf-sdl2-net.1/opam

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@ opam-version: "2.0"
22
maintainer: "https://github.com/ocaml/opam-repository/issues"
33
homepage: "http://www.libsdl.org/projects/SDL_net/"
44
license: "Zlib"
5-
build: [["pkg-config" "SDL2_net"]]
5+
build: [
6+
["pkgconf" "--personality=i686-w64-mingw32" "SDL2_net"] {os = "win32" & os-distribution = "cygwin" & host-arch-x86_32:installed}
7+
["pkgconf" "--personality=x86_64-w64-mingw32" "SDL2_net"] {os = "win32" & os-distribution = "cygwin" & host-arch-x86_64:installed}
8+
["pkg-config" "SDL2_net"] {os != "win32" | os-distribution != "cygwin"}
9+
]
610
depexts: [
711
["sdl2_net"] {os-family = "arch"}
812
["sdl2_net-dev"] {os-distribution = "alpine"}
@@ -22,7 +26,11 @@ x-ci-accept-failures: [
2226
synopsis: "Virtual package relying on a sdl2-net system installation"
2327
description:
2428
"This package can only install if libsdl2-net is installed on the system."
25-
depends: ["conf-pkg-config" {build}]
29+
depends: [
30+
"conf-pkg-config" {build}
31+
("host-arch-x86_32" {os = "win32" & os-distribution != "cygwinports"} & "conf-mingw-w64-sdl2-net-i686" {os = "win32" & os-distribution != "cygwinports"} |
32+
"host-arch-x86_64" {os = "win32" & os-distribution != "cygwinports"} & "conf-mingw-w64-sdl2-net-x86_64" {os = "win32" & os-distribution != "cygwinports"})
33+
]
2634
bug-reports: "https://github.com/ocaml/opam-repository/issues"
2735
authors: "Sam Lantinga"
2836
flags: conf

0 commit comments

Comments
 (0)