Ticket #28276: patch-ARB-makefile.diff

File patch-ARB-makefile.diff, 2.2 KB (added by matt.cottrell@…, 14 years ago)

No longer linking against libpng in /usr/X11R6

  • Makefile

    old new  
    3131#                       configurable in config.makefile
    3232#
    3333# -----------------------------------------------------
     34
    3435# Read configuration
    3536include config.makefile
    3637
    3738ifeq ($(LD_LIBRARY_PATH),'')
    38 LD_LIBRARY_PATH:=${ARBHOME}/lib
     39        LD_LIBRARY_PATH:=${ARBHOME}/lib
    3940endif
    4041
    4142FORCEMASK = umask 002
     
    4647GPP:=g++
    4748CPPreal:=cpp
    4849
    49 
    50 
    5150# ---------------------- compiler version detection
    5251
    5352# supported compiler versions:
     
    203202XINCLUDES:=-I$(XHOME)/include
    204203
    205204ifdef DARWIN
    206         XINCLUDES := -I/sw/include -I$(OSX_SDK)/usr/X11/include -I$(OSX_SDK)/usr/include/krb5 -I/usr/OpenMotif/include #Snow Leopard couldn't find OpenMotif
     205        XINCLUDES := -I$(OSX_FW)/OpenGL.framework/Headers -I$(OSX_SDK)/usr/X11/include -I$(OSX_SDK)/usr/include/krb5 -I$(OSX_FW)/GLUT.framework/Headers -I$(PREFIX)/include
    207206endif
    208207
    209208ifdef DARWIN
    210         XLIBS := -L/usr/OpenMotif/lib -lXm -L$(XHOME)/lib -lpng -lXt -lX11 -lXext -lXp -lc -lXmu -lXi
     209    #Explicit use of png12 because ARB breaks with png14 (http://www.libpng.org/pub/png/src/libpng-1.2.x-to-1.4.x-summary.txt)
     210        XLIBS := -L$(PREFIX)/lib -lXm -lpng12 -lz -L$(XHOME)/lib -lXt -lX11 -lXext -lXp -lc -lXmu -lXi
    211211        XLIBS += -lGLU -lGL -Wl,-dylib_file,$(OSX_FW_OPENGL)/libGL.dylib:$(OSX_FW_OPENGL)/libGL.dylib
    212212else
    213213        XLIBS:=-L$(XHOME)/$(CROSS_LIB) -lXm -lXpm -lXp -lXt -lXext -lX11
     
    226226
    227227GL_PNGLIBS := -L$(ARBHOME)/GL/glpng -lglpng_arb -lpng
    228228
    229  ifdef DARWIN
    230         GLEWLIB := -L/usr/lib -lGLEW -L$(OSX_SDK)/usr/X11/lib -lGLw
    231         GLUTLIB := -L$(XHOME)/lib -lglut
    232  else
    233         GLEWLIB := -lGLEW -lGLw
    234         GLUTLIB := -lglut
    235  endif
    236 
     229GLEWLIB := -lGLEW -lGLw
     230GLUTLIB := -lglut
     231 
    237232GL_LIBS := $(GL_LIB) $(GLEWLIB) $(GLUTLIB) $(GL_PNGLIBS)
    238233
    239234#XLIBS += $(GL_LIB)
     
    248243
    249244#---------------------- tiff lib:
    250245
    251 ifdef DARWIN
    252         TIFFLIBS := -L/usr/local/lib -ltiff -L$(OSX_FW_IMAGEIO) -lTIFF 
    253 else
    254         TIFFLIBS := -ltiff
    255 endif
     246TIFFLIBS := -ltiff
    256247
    257248#---------------------- basic libs:
    258249
     
    319310
    320311CTAGS := etags
    321312ifdef DARWIN
    322         XMKMF := /usr/X11/bin/xmkmf
     313        XMKMF := $(PREFIX)/bin/xmkmf
    323314else
    324315        XMKMF := /usr/bin/X11/xmkmf
    325316endif