diff --git a/Info.plist b/Info.plist
index b5d2a5aa..b2bfa1c1 100644
--- a/Info.plist
+++ b/Info.plist
@@ -7,7 +7,7 @@
CFBundleExecutable
Grafx2
CFBundleIconFile
-
+ Grafx2.icns
CFBundleIdentifier
com.googlecode.grafx2
CFBundleInfoDictionaryVersion
diff --git a/src/.DS_Store b/src/.DS_Store
index 099fb472..6f0fb88d 100644
Binary files a/src/.DS_Store and b/src/.DS_Store differ
diff --git a/src/Grafx2.icns b/src/Grafx2.icns
new file mode 100755
index 00000000..3d0bfa34
Binary files /dev/null and b/src/Grafx2.icns differ
diff --git a/src/Makefile b/src/Makefile
index ae96bb97..79cc11ba 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -32,6 +32,10 @@
# Compile with OPTIM=0 to disable gcc optimizations, to enable debug.
STRIP = strip
+### Specific to build MAC OS X universal binaries on Tiger ###
+### (may need to be changed on your OS) ###
+
+MACOSX_SYSROOT = /Developer/SDKs/MacOSX10.4u.sdk
### PLATFORM DETECTION AND CONFIGURATION ###
@@ -83,17 +87,19 @@ else
DELCOMMAND = rm -rf
MKDIR = mkdir -p
RMDIR = rmdir
+ # Force it
+ #OPTIM = 3
CP = cp
ZIP = zip
PLATFORMFILES = gfx2.png
- BIN = ../bin/grafx2
# Where the SDL frameworks are located
FWDIR = /Library/Frameworks
- SDLCOPT = -arch ppc -I$(FWDIR)/SDL.framework/Headers -I$(FWDIR)/SDL_image.framework/Headers -I$(FWDIR)/SDL_ttf.framework/Headers -D_THREAD_SAFE
+ BIN = ../bin/grafx2
+ SDLCOPT = -arch ppc -arch i386 -I$(FWDIR)/SDL.framework/Headers -I$(FWDIR)/SDL_image.framework/Headers -I$(FWDIR)/SDL_ttf.framework/Headers -D_THREAD_SAFE
#-framework SDL_ttf
- SDLLOPT = -arch ppc -L/usr/lib -framework SDL -framework SDL_image -framework Cocoa -framework Carbon -framework OpenGL
+ SDLLOPT = -isysroot $(MACOSX_SYSROOT) -arch ppc -arch i386 -L/usr/lib -framework SDL -framework SDL_image -framework Cocoa -framework Carbon -framework OpenGL
COPT = -D_DARWIN_C_SOURCE -D__macosx__ -D__linux__ -W -Wall -Wdeclaration-after-statement -O$(OPTIM) -std=c99 -c -g $(SDLCOPT) $(TTFCOPT) -I/usr/X11/include
- LOPT = $(SDLLOPT) -lpng
+ LOPT = $(SDLLOPT) -lpng -lz
# Use gcc for compiling. Use ncc to build a callgraph and analyze the code.
CC = gcc
#CC = nccgen -ncgcc -ncld -ncfabs
@@ -382,6 +388,7 @@ $(MACAPPEXE) : $(BIN)
mkdir -p Grafx2.app Grafx2.app/Contents Grafx2.app/Contents/Frameworks Grafx2.app/Contents/MacOS Grafx2.app/Contents/Resources
echo 'APPL????' > Grafx2.app/Contents/PkgInfo
cp ../Info.plist Grafx2.app/Contents
+ cp -r Grafx2.icns Grafx2.app/Contents/Resources
cp -r English.lproj Grafx2.app/Contents/Resources
cp -r ../share/grafx2/fonts Grafx2.app/Contents/Resources
cp -r ../share/grafx2/skins Grafx2.app/Contents/Resources
@@ -399,6 +406,8 @@ $(MACAPPEXE) : $(BIN)
# rm -fr Grafx2.app/Contents/Frameworks/SDL_ttf.framework/Versions
# rm -fr Grafx2.app/Contents/Frameworks/SDL_ttf.framework/Versions
cp $(BIN) $(MACAPPEXE)
+ $(STRIP) -x -X -S $(MACAPPEXE)
+ chmod +x $(MACAPPEXE)
else
all : $(BIN)
endif
diff --git a/src/buttons.c b/src/buttons.c
index ee99605b..2d43c572 100644
--- a/src/buttons.c
+++ b/src/buttons.c
@@ -169,7 +169,7 @@ void Button_Message_initial(void)
for (x=14,x_pos=0; x_pos<231; x_pos++,x++)
Pixel_in_window(x,y,Gfx->Logo_grafx2[offs_y+x_pos]);
- Print_in_window(130-4*26,88,"Copyright (c) 2007-2010 by",MC_Dark,MC_Light);
+ Print_in_window(130-4*26,88,"Copyright (c) 2007-2011 by",MC_Dark,MC_Light);
Print_in_window(130-4*23,96,"the Grafx2 project team",MC_Black,MC_Light);
Print_in_window(130-4*26,112,"Copyright (c) 1996-2001 by",MC_Dark,MC_Light);
Print_in_window(130-4*13,120,"Sunset Design",MC_Black,MC_Light);
diff --git a/src/fileformats.c b/src/fileformats.c
index 163e4e45..4f6b1d1b 100644
--- a/src/fileformats.c
+++ b/src/fileformats.c
@@ -28,6 +28,9 @@
#ifndef __no_pnglib__
#include
+#if !defined(PNG_HAVE_PLTE)
+#define PNG_HAVE_PLTE 0x02
+#endif
#if (PNG_LIBPNG_VER_MAJOR <= 1) && (PNG_LIBPNG_VER_MINOR < 4)
// Compatibility layer to allow us to use libng 1.4 or any older one.
diff --git a/src/helpfile.h b/src/helpfile.h
index 4d95e3ca..e878af88 100644
--- a/src/helpfile.h
+++ b/src/helpfile.h
@@ -67,7 +67,7 @@ static const T_Help_table helptable_about[] =
#else
HELP_TEXT ("")
#endif
- HELP_TEXT ("Copyright 2007-2010, the Grafx2 project team")
+ HELP_TEXT ("Copyright 2007-2011, the Grafx2 project team")
HELP_TEXT (" Copyright 1996-2001, SUNSET DESIGN")
};
static const T_Help_table helptable_licence[] =