Linux info for EGL, OSMesa and Mingw-64 builds

This commit is contained in:
Nigel Stewart 2018-10-10 12:29:15 +10:00
parent d73ad7eeb2
commit a8ebd2819e
4 changed files with 29 additions and 35 deletions

View File

@ -39,7 +39,7 @@ For most end-users of GLEW the official releases are the best choice, with first
##### Install build tools ##### Install build tools
Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libxmu-dev libxi-dev libgl-dev libosmesa-dev` Debian/Ubuntu/Mint: `$ sudo apt-get install build-essential libxmu-dev libxi-dev libgl-dev`
RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel` RedHat/CentOS/Fedora: `$ sudo yum install libXmu-devel libXi-devel libGL-devel`
@ -55,6 +55,22 @@ Variables: `SYSTEM=linux-clang, GLEW_DEST=/usr/local, STRIP=`
_Note: may need to make **auto** folder_ _Note: may need to make **auto** folder_
##### Linux EGL
$ sudo apt install libegl1-mesa-dev
$ make SYSTEM=linux-egl
##### Linux OSMesa
$ sudo apt install libosmesa-dev
$ make SYSTEM=linux-osmesa
##### Linux OSMesa
$ sudo apt install mingw-w64
$ make SYSTEM=linux-mingw32
$ make SYSTEM=linux-mingw64
#### Using cmake #### Using cmake
*CMake 2.8.12 or higher is required.* *CMake 2.8.12 or higher is required.*

View File

@ -1,22 +0,0 @@
# For cross-compiling from Linux to Windows x86 using mingw-w64
# http://mingw-w64.sourceforge.net/
#
# $ make SYSTEM=linux-mingw-w64
#
NAME := glew32
CC := i686-w64-mingw32-gcc
LD := i686-w64-mingw32-ld
LN :=
STRIP :=
LDFLAGS.GL = -lopengl32 -lgdi32 -luser32 -lkernel32
CFLAGS.EXTRA += -fno-builtin -fno-stack-protector
LDFLAGS.EXTRA += -nostdlib
WARN = -Wall -W
POPT = -O2
BIN.SUFFIX = .exe
LIB.SONAME = lib$(NAME).dll
LIB.DEVLNK = lib$(NAME).dll.a # for mingw this is the dll import lib
LIB.SHARED = $(NAME).dll
LIB.STATIC = lib$(NAME).a # the static lib will be broken
LDFLAGS.SO = -shared -soname $(LIB.SONAME) --out-implib lib/$(LIB.DEVLNK)

View File

@ -1,17 +1,17 @@
# For cross-compiling from Linux to Windows x86 using mingw32 # For cross-compiling from Linux to Windows 32-bit using mingw32
# http://www.mingw.org/ # http://mingw-w64.org/
# #
# $ sudo apt install mingw-w64
# $ make SYSTEM=linux-mingw32 # $ make SYSTEM=linux-mingw32
NAME := glew32 NAME := glew32
HOST := i586-mingw32msvc HOST := i686-w64-mingw32
CC := $(HOST)-gcc CC := $(HOST)-gcc
LD := $(HOST)-ld LD := $(HOST)-ld
LN := LN :=
STRIP := STRIP :=
LDFLAGS.GL = -lopengl32 -lgdi32 -luser32 -lkernel32 LDFLAGS.GL = -L/usr/$(HOST)/lib -lopengl32 -lgdi32 -luser32 -lkernel32
CFLAGS.EXTRA += -fno-builtin -fno-stack-protector CFLAGS.EXTRA += -fno-builtin -fno-stack-protector
#LDFLAGS.EXTRA += -nostdlib
WARN = -Wall -W WARN = -Wall -W
POPT = -O2 POPT = -O2
BIN.SUFFIX = .exe BIN.SUFFIX = .exe
@ -19,4 +19,4 @@ LIB.SONAME = lib$(NAME).dll
LIB.DEVLNK = lib$(NAME).dll.a # for mingw this is the dll import lib LIB.DEVLNK = lib$(NAME).dll.a # for mingw this is the dll import lib
LIB.SHARED = $(NAME).dll LIB.SHARED = $(NAME).dll
LIB.STATIC = lib$(NAME).a # the static lib will be broken LIB.STATIC = lib$(NAME).a # the static lib will be broken
LDFLAGS.SO = -shared -soname $(LIB.SONAME) --out-implib lib/$(LIB.DEVLNK) LDFLAGS.SO = -nostdlib -shared -soname $(LIB.SONAME) --out-implib lib/$(LIB.DEVLNK)

View File

@ -1,17 +1,17 @@
# For cross-compiling from Linux to Windows amd64 using mingw32 # For cross-compiling from Linux to Windows 64-bit using mingw64
# http://www.mingw.org/ # http://mingw-w64.org/
# #
# $ sudo apt install mingw-w64
# $ make SYSTEM=linux-mingw64 # $ make SYSTEM=linux-mingw64
NAME := glew32 NAME := glew32
HOST := i686-w64-mingw32 HOST := x86_64-w64-mingw32
CC := $(HOST)-gcc CC := $(HOST)-gcc
LD := $(HOST)-ld LD := $(HOST)-ld
LN := LN :=
STRIP := STRIP :=
LDFLAGS.GL = -lopengl32 -lgdi32 -luser32 -lkernel32 LDFLAGS.GL = -L/usr/$(HOST)/lib -lopengl32 -lgdi32 -luser32 -lkernel32
CFLAGS.EXTRA += -fno-builtin -fno-stack-protector CFLAGS.EXTRA += -fno-builtin -fno-stack-protector
#LDFLAGS.EXTRA += -nostdlib
WARN = -Wall -W WARN = -Wall -W
POPT = -O2 POPT = -O2
BIN.SUFFIX = .exe BIN.SUFFIX = .exe
@ -19,4 +19,4 @@ LIB.SONAME = lib$(NAME).dll
LIB.DEVLNK = lib$(NAME).dll.a # for mingw this is the dll import lib LIB.DEVLNK = lib$(NAME).dll.a # for mingw this is the dll import lib
LIB.SHARED = $(NAME).dll LIB.SHARED = $(NAME).dll
LIB.STATIC = lib$(NAME).a # the static lib will be broken LIB.STATIC = lib$(NAME).a # the static lib will be broken
LDFLAGS.SO = -shared -soname $(LIB.SONAME) --out-implib lib/$(LIB.DEVLNK) LDFLAGS.SO = -nostdlib -shared -soname $(LIB.SONAME) --out-implib lib/$(LIB.DEVLNK)