internal/glfw/glfw: refactoring: remove glfw/include

This commit is contained in:
Hajime Hoshi 2023-07-10 23:29:25 +09:00
parent 58f1415cac
commit bf197e379b
15 changed files with 12 additions and 21 deletions

View File

@ -16,6 +16,5 @@ package glfw
// - this file is given a build to exclude it from the regular build. // - this file is given a build to exclude it from the regular build.
import ( import (
// Prevent go tooling from stripping out the c source files. // Prevent go tooling from stripping out the c source files.
_ "github.com/hajimehoshi/ebiten/v2/internal/glfw/glfw/glfw/include/GLFW"
_ "github.com/hajimehoshi/ebiten/v2/internal/glfw/glfw/glfw/src" _ "github.com/hajimehoshi/ebiten/v2/internal/glfw/glfw/glfw/src"
) )

View File

@ -8,7 +8,7 @@ package glfw
//#include <stdlib.h> //#include <stdlib.h>
//#define GLFW_INCLUDE_NONE //#define GLFW_INCLUDE_NONE
//#include "glfw/include/GLFW/glfw3.h" //#include "glfw3.h"
import "C" import "C"
import ( import (

View File

@ -7,7 +7,7 @@
package glfw package glfw
// #define GLFW_INCLUDE_NONE // #define GLFW_INCLUDE_NONE
// #include "glfw/include/GLFW/glfw3.h" // #include "glfw3.h"
// //
// void goErrorCB(int code, char* desc); // void goErrorCB(int code, char* desc);
// //

View File

@ -8,7 +8,7 @@ package glfw
//#include <stdlib.h> //#include <stdlib.h>
//#define GLFW_INCLUDE_NONE //#define GLFW_INCLUDE_NONE
//#include "glfw/include/GLFW/glfw3.h" //#include "glfw3.h"
import "C" import "C"
import "unsafe" import "unsafe"

View File

@ -1,4 +0,0 @@
//go:build required
// Package dummy prevents go tooling from stripping the c dependencies.
package dummy

View File

@ -1,4 +0,0 @@
//go:build required
// Package dummy prevents go tooling from stripping the c dependencies.
package dummy

View File

@ -8,7 +8,7 @@ package glfw
// #include <stdlib.h> // #include <stdlib.h>
// #define GLFW_INCLUDE_NONE // #define GLFW_INCLUDE_NONE
// #include "glfw/include/GLFW/glfw3.h" // #include "glfw3.h"
// //
// void goKeyCB(void* window, int key, int scancode, int action, int mods); // void goKeyCB(void* window, int key, int scancode, int action, int mods);
// void goCharCB(void* window, unsigned int character); // void goCharCB(void* window, unsigned int character);

View File

@ -7,7 +7,7 @@
package glfw package glfw
// #define GLFW_INCLUDE_NONE // #define GLFW_INCLUDE_NONE
// #include "glfw/include/GLFW/glfw3.h" // #include "glfw3.h"
// //
// void goMonitorCB(void* monitor, int event); // void goMonitorCB(void* monitor, int event);
// //

View File

@ -7,8 +7,8 @@ package glfw
/* /*
#define GLFW_EXPOSE_NATIVE_COCOA #define GLFW_EXPOSE_NATIVE_COCOA
#define GLFW_EXPOSE_NATIVE_NSGL #define GLFW_EXPOSE_NATIVE_NSGL
#include "glfw/include/GLFW/glfw3.h" #include "glfw3.h"
#include "glfw/include/GLFW/glfw3native.h" #include "glfw3native.h"
// workaround wrappers needed due to a cgo and/or LLVM bug. // workaround wrappers needed due to a cgo and/or LLVM bug.
// See: https://github.com/go-gl/glfw/issues/136 // See: https://github.com/go-gl/glfw/issues/136

View File

@ -10,8 +10,8 @@ package glfw
//#define GLFW_EXPOSE_NATIVE_WAYLAND //#define GLFW_EXPOSE_NATIVE_WAYLAND
//#define GLFW_EXPOSE_NATIVE_EGL //#define GLFW_EXPOSE_NATIVE_EGL
//#define GLFW_INCLUDE_NONE //#define GLFW_INCLUDE_NONE
//#include "glfw/include/GLFW/glfw3.h" //#include "glfw3.h"
//#include "glfw/include/GLFW/glfw3native.h" //#include "glfw3native.h"
import "C" import "C"
func GetWaylandDisplay() *C.struct_wl_display { func GetWaylandDisplay() *C.struct_wl_display {

View File

@ -10,8 +10,8 @@ package glfw
//#define GLFW_EXPOSE_NATIVE_X11 //#define GLFW_EXPOSE_NATIVE_X11
//#define GLFW_EXPOSE_NATIVE_GLX //#define GLFW_EXPOSE_NATIVE_GLX
//#define GLFW_INCLUDE_NONE //#define GLFW_INCLUDE_NONE
//#include "glfw/include/GLFW/glfw3.h" //#include "glfw3.h"
//#include "glfw/include/GLFW/glfw3native.h" //#include "glfw3native.h"
import "C" import "C"
import "unsafe" import "unsafe"

View File

@ -8,7 +8,7 @@ package glfw
// #include <stdlib.h> // #include <stdlib.h>
// #define GLFW_INCLUDE_NONE // #define GLFW_INCLUDE_NONE
// #include "glfw/include/GLFW/glfw3.h" // #include "glfw3.h"
// //
// void goWindowPosCB(void* window, int xpos, int ypos); // void goWindowPosCB(void* window, int xpos, int ypos);
// void goWindowSizeCB(void* window, int width, int height); // void goWindowSizeCB(void* window, int width, int height);