Actual minimal patch to compile goyaml with mingw32
diff --git a/api.c b/api.c
index d513abc..0c4732e 100644
--- a/api.c
+++ b/api.c
@@ -1,6 +1,5 @@
 
 #include "yaml_private.h"
-#include "helpers.h"
 
 /*
  * Get the library version.
diff --git a/decode.go b/decode.go
index b5046c5..a60dfdb 100644
--- a/decode.go
+++ b/decode.go
@@ -1,7 +1,7 @@
 package goyaml
 
 // #cgo LDFLAGS: -lm -lpthread
-// #cgo windows CFLAGS: -DYAML_DECLARE_STATIC=1
+// #cgo windows CFLAGS: -DYAML_DECLARE_STATIC=1 -Dstrdup=_strdup
 // #cgo CFLAGS: -I. -DHAVE_CONFIG_H=1
 //
 // #include "helpers.h"
diff --git a/helpers.h b/helpers.h
index 0a2efaa..e4d8639 100644
--- a/helpers.h
+++ b/helpers.h
@@ -1,9 +1,8 @@
 #ifndef helpers_h
 #define helpers_h
 
-#ifdef _WIN32
-#define strdup _strdup
-#endif
+#define CGO_LDFLAGS "-lm -lpthread"
+#define CGO_CFLAGS "-I. -DHAVE_CONFIG_H=1"
 
 #include <yaml.h>