Skip to content
Snippets Groups Projects
Commit 68fa7164 authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

Don't use LITTLE_ENDIAN, it may be defined on Macs and cause the
colormap problems. Define and test _BIG_ENDIAN instead.

Change NODLL to _NO_DLL
parent f32d6052
No related branches found
No related tags found
No related merge requests found
......@@ -24,18 +24,18 @@
// How RGBA values are packed and unpacked into/from a 4-byte integer
#ifdef LITTLE_ENDIAN
# define PACK_COLOR(R,G,B,A) ( (A)<<24 | (B)<<16 | (G)<<8 | (R) )
# define UNPACK_RED(X) ( (X) & 0xff )
# define UNPACK_GREEN(X) ( ( (X) >> 8 ) & 0xff )
# define UNPACK_BLUE(X) ( ( (X) >> 16 ) & 0xff )
# define UNPACK_ALPHA(X) ( ( (X) >> 24 ) & 0xff )
#else
#if defined(_BIG_ENDIAN)
# define PACK_COLOR(R,G,B,A) ( (R)<<24 | (G)<<16 | (B)<<8 | (A) )
# define UNPACK_RED(X) ( ( (X) >> 24 ) & 0xff )
# define UNPACK_GREEN(X) ( ( (X) >> 16 ) & 0xff )
# define UNPACK_BLUE(X) ( ( (X) >> 8 ) & 0xff )
# define UNPACK_ALPHA(X) ( (X) & 0xff )
#else
# define PACK_COLOR(R,G,B,A) ( (A)<<24 | (B)<<16 | (G)<<8 | (R) )
# define UNPACK_RED(X) ( (X) & 0xff )
# define UNPACK_GREEN(X) ( ( (X) >> 8 ) & 0xff )
# define UNPACK_BLUE(X) ( ( (X) >> 16 ) & 0xff )
# define UNPACK_ALPHA(X) ( ( (X) >> 24 ) & 0xff )
#endif
// Interface-independent context
......
// $Id: Plugin.cpp,v 1.35 2003-02-12 20:27:14 geuzaine Exp $
// $Id: Plugin.cpp,v 1.36 2003-02-17 16:32:37 geuzaine Exp $
//
// Copyright (C) 1997 - 2003 C. Geuzaine, J.-F. Remacle
//
......@@ -19,7 +19,7 @@
//
// Please report all bugs and problems to "gmsh@geuz.org".
#if !defined(NODLL)
#if !defined(_NO_DLL)
#include <dlfcn.h>
#endif
......@@ -161,7 +161,7 @@ void GMSH_PluginManager::RegisterDefaultPlugins(){
void GMSH_PluginManager::AddPlugin( char *dirName, char *pluginName){
#if defined(NODLL) || !defined(HAVE_FLTK)
#if defined(_NO_DLL) || !defined(HAVE_FLTK)
Msg(WARNING,"No dynamic plugin loading on this platform");
return;
#else
......
......@@ -3199,12 +3199,12 @@ case "$UNAME" in
;;
Darwin*)
OS_FLAGS="${OS_FLAGS} -DNODLL"
OS_FLAGS="${OS_FLAGS} -D_NO_DLL"
POSTBUILD="/Developer/Tools/Rez -t APPL -o bin/gmsh Fltk/MacRes.r"
;;
AIX*)
OS_FLAGS="${OS_FLAGS} -D_BSD -DNODLL"
OS_FLAGS="${OS_FLAGS} -D_BSD -D_NO_DLL"
;;
IRIX*)
......@@ -3217,12 +3217,12 @@ case "$UNAME" in
;;
SunOS*)
OS_FLAGS="${OS_FLAGS} -DNODLL"
OS_FLAGS="${OS_FLAGS} -D_NO_DLL"
GMSH_LIBS="${GMSH_LIBS} -lsocket -lnsl -ldl"
;;
HP-UX*)
OS_FLAGS="-DNODLL"
OS_FLAGS="-D_NO_DLL"
;;
esac
......@@ -3414,9 +3414,9 @@ echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
echo "${ECHO_T}$ac_cv_c_bigendian" >&6
case $ac_cv_c_bigendian in
yes)
OS_FLAGS="${OS_FLAGS}" ;;
OS_FLAGS="${OS_FLAGS} -D_BIG_ENDIAN" ;;
no)
OS_FLAGS="-DLITTLE_ENDIAN ${OS_FLAGS}" ;;
;;
*)
{ { echo "$as_me:$LINENO: error: unknown endianess
presetting ac_cv_c_bigendian=no (or yes) will help" >&5
......
dnl "$Id: configure.in,v 1.22 2003-02-17 01:52:55 geuzaine Exp $"
dnl "$Id: configure.in,v 1.23 2003-02-17 16:32:37 geuzaine Exp $"
dnl
dnl Copyright (C) 1997 - 2003 C. Geuzaine, J.-F. Remacle
dnl
......@@ -162,12 +162,12 @@ case "$UNAME" in
;;
Darwin*)
OS_FLAGS="${OS_FLAGS} -DNODLL"
OS_FLAGS="${OS_FLAGS} -D_NO_DLL"
POSTBUILD="/Developer/Tools/Rez -t APPL -o bin/gmsh Fltk/MacRes.r"
;;
AIX*)
OS_FLAGS="${OS_FLAGS} -D_BSD -DNODLL"
OS_FLAGS="${OS_FLAGS} -D_BSD -D_NO_DLL"
;;
IRIX*)
......@@ -180,18 +180,18 @@ case "$UNAME" in
;;
SunOS*)
OS_FLAGS="${OS_FLAGS} -DNODLL"
OS_FLAGS="${OS_FLAGS} -D_NO_DLL"
GMSH_LIBS="${GMSH_LIBS} -lsocket -lnsl -ldl"
;;
HP-UX*)
OS_FLAGS="-DNODLL"
OS_FLAGS="-D_NO_DLL"
;;
esac
dnl Is the machine big or littke endian?
AC_C_BIGENDIAN(OS_FLAGS="${OS_FLAGS}",OS_FLAGS="-DLITTLE_ENDIAN ${OS_FLAGS}")
AC_C_BIGENDIAN(OS_FLAGS="${OS_FLAGS} -D_BIG_ENDIAN")
AC_SUBST(OPT_FLAGS)
AC_SUBST(OS_FLAGS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment