HaikuPorts
  • Login
  • Preferences
  • Help/Guide
  • Wiki
  • Timeline
  • Roadmap
  • View Tickets
  • Search
  • Port Log
  • Blog

Context Navigation

  • Back to Ticket #390

Ticket #390: celestia-1.6.0.patch

File celestia-1.6.0.patch, 4.2 KB (added by michaelvoliveira, 5 years ago)

Patch file to avoid UNIXs especifc functions and GLX

  • configure.in

    diff -Naur celestia-1.6.0/configure.in celestia-1.6.0-haiku/configure.in
    old new  
    193193AM_CONDITIONAL(ENABLE_SPICE, test "$SPICELIB" != "") 
    194194 
    195195 
    196 LIBS="$LIBS -lm" 
     196LIBS="$LIBS -lintl" 
    197197 
    198198dnl Use Gtk if requested 
    199199GTK_LIBS="" 
    … …  
    237237CFLAGS="$CFLAGS $CELESTIAFLAGS $CELESTIA_CFLAGS" 
    238238CXXFLAGS="$CXXFLAGS $CELESTIAFLAGS $CELESTIA_CXXFLAGS" 
    239239LIBS="$LIBS $CELESTIALIBS" 
    240 LIBS="$X_PRE_LIBS $LIBS $X_LIBS -lXmu -lXi -lXext -lX11 -lm -lz $X_EXTRA_LIBS" 
     240LIBS="$X_PRE_LIBS $LIBS $X_LIBS -lz $X_EXTRA_LIBS" 
    241241 
    242242dnl Check for zlib -- libGL requires it. 
    243243AC_CHECK_LIB(z, deflate, , 
  • data/Makefile.am

    diff -Naur celestia-1.6.0/data/Makefile.am celestia-1.6.0-haiku/data/Makefile.am
    old new  
    1515        $(wildcard *.xyz) \ 
    1616        $(wildcard *.xyzv) \ 
    1717        $(wildcard *.dsc) \ 
    18         $(wildcard *.stc) \ 
    19         stars.dat 
     18        $(wildcard *.stc) 
    2019 
    2120EXTRA_DIST = \ 
    2221        $(pkgdata_DATA) \ 
  • src/celengine/astro.cpp

    diff -Naur celestia-1.6.0/src/celengine/astro.cpp celestia-1.6.0-haiku/src/celengine/astro.cpp
    old new  
    522522    cal_time.tm_sec = (int)seconds; 
    523523    cal_time.tm_wday = wday; 
    524524    cal_time.tm_gmtoff = utc_offset; 
    525 #if defined(TARGET_OS_MAC) || defined(__FreeBSD__) 
     525#if defined(TARGET_OS_MAC) || defined(__FreeBSD__) || defined(__HAIKU__) 
    526526    // tm_zone is a non-const string field on the Mac and FreeBSD (why?) 
    527527    cal_time.tm_zone = const_cast<char*>(tzname.c_str()); 
    528528#else 
  • src/celengine/glext.cpp

    diff -Naur celestia-1.6.0/src/celengine/glext.cpp celestia-1.6.0-haiku/src/celengine/glext.cpp
    old new  
    1212 
    1313#ifndef _WIN32 
    1414// Assume that this is a UNIX/X11 system if it's not Windows or Mac OS X. 
    15 #ifndef TARGET_OS_MAC 
     15#if !defined(TARGET_OS_MAC) && !defined(__HAIKU__) 
    1616#include "GL/glx.h" 
    1717#include <dlfcn.h> 
    18 #endif /* ! TARGET_OS_MAC */ 
     18#endif /* ! TARGET_OS_MAC || HAIKU */ 
    1919#endif /* ! _WIN32 */ 
    2020 
    2121#include "glext.h" 
    … …  
    306306 
    307307#else 
    308308 
    309 #ifndef TARGET_OS_MAC 
     309#if !defined(TARGET_OS_MAC) && !defined(__HAIKU__) 
    310310#if defined(_WIN32) 
    311311 
    312312#define GET_GL_PROC_ADDRESS(name) wglGetProcAddress(name) 
    … …  
    692692 
    693693static void InitExt_GLX_SGI_video_sync() 
    694694{ 
     695#if defined(GET_GL_PROC_ADDRESS) 
    695696    glx::glXGetVideoSyncSGI = (glx::PFNGLXGETVIDEOSYNCSGIPROC) GET_GL_PROC_ADDRESS("glXGetVideoSyncSGI"); 
    696697    glx::glXWaitVideoSyncSGI = (glx::PFNGLXWAITVIDEOSYNCSGIPROC) GET_GL_PROC_ADDRESS("glXWaitVideoSyncSGI"); 
    697698    glx::glXGetRefreshRateSGI = (glx::PFNGLXGETREFRESHRATESGIPROC) GET_GL_PROC_ADDRESS("glXGetRefreshRateSGI"); 
     699#endif 
    698700} 
    699701 
    700702 
  • src/celengine/image.cpp

    diff -Naur celestia-1.6.0/src/celengine/image.cpp celestia-1.6.0-haiku/src/celengine/image.cpp
    old new  
    737737 
    738738    if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) 
    739739    { 
    740         png_set_gray_1_2_4_to_8(png_ptr); 
     740        png_set_expand_gray_1_2_4_to_8(png_ptr); 
    741741    } 
    742742 
    743743    if (png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS)) 
  • src/celutil/unixdirectory.cpp

    diff -Naur celestia-1.6.0/src/celutil/unixdirectory.cpp celestia-1.6.0-haiku/src/celutil/unixdirectory.cpp
    old new  
    1111#include <sys/stat.h> 
    1212#include <unistd.h> 
    1313#include <dirent.h> 
     14#if !defined(__HAIKU__) 
    1415#include <wordexp.h> 
     16#endif 
    1517#include "directory.h" 
    1618 
    1719using namespace std; 
    1820 
    1921 
    20 #ifdef TARGET_OS_MAC 
    21 #ifdef QT_CORE_LIB 
     22#if defined(__HAIKU__) || defined(TARGET_OS_MAC) && defined(QT_CORE_LIB) 
    2223// Crash on Mac OS X / Qt4 version when calling wordfree. 
    2324// This seems to happen only with Leopard. 
    2425#define WORDEXP_PROBLEM 
    2526#endif 
    26 #endif 
    2727 
    2828class UnixDirectory : public Directory 
    2929{ 

Download in other formats:

  • Original Format

Trac Powered

Powered by Trac 0.13dev-r10686
By Edgewall Software.

Visit the Trac open source project at
http://trac.edgewall.org/