src/main/Makefile.am
author Sam Lantinga <slouken@libsdl.org>
Sun, 21 Sep 2003 18:32:04 +0000
changeset 720 f90d80d68071
parent 371 db0cc6034336
child 754 623b453a3219
permissions -rw-r--r--
N Sep 17 8791 Sam Lantinga Re: tks source released
Date: Sun, 07 Sep 2003 02:51:58 +0200
From: Stephane Marchesin
Subject: [SDL] Two little patches

Compiling SDL with a recent gcc (gcc 3.3.1, 3.3 doesn't have this
behaviour) gives some nasty warnings :

SDL_blit_A.c: In function `BlitRGBtoRGBSurfaceAlpha128MMX':
SDL_blit_A.c:223: warning: integer constant is too large for "long" type
SDL_blit_A.c:225: warning: integer constant is too large for "long" type
SDL_blit_A.c:227: warning: integer constant is too large for "long" type
[...]

The first attached patch (longlongfix.patch) tells gcc to really treat
those constants as unsigned long long and not long.

The second patch (nasinclude.patch) fixes an include problem I had while
compiling nas audio : when the <audio/audiolib.h> file lies in
/usr/X11R6/include, a -I/usr/X11R6/include option is needed or the file
isn't found.
     1 
     2 ## Makefile.am for the main() function in the SDL library
     3 #
     4 # This is necessary because some platforms have special program
     5 # entry points, which require special application initialization.
     6 
     7 ARCH_SUBDIRS = $(srcdir)/beos \
     8                $(srcdir)/epoc \
     9                $(srcdir)/linux \
    10                $(srcdir)/macos \
    11                $(srcdir)/macosx \
    12                $(srcdir)/win32
    13 
    14 # Build a separate library containing the main() entry point.
    15 lib_LIBRARIES = libSDLmain.a
    16 
    17 if TARGET_MACOSX
    18 MAINLIB_ARCH_SRCS = SDLMain.m SDLMain.h
    19 else
    20 if TARGET_QTOPIA
    21 MAINLIB_ARCH_SRCS = SDL_Qtopia_main.cc
    22 else
    23 MAINLIB_ARCH_SRCS = SDL_main.c
    24 endif
    25 endif
    26 libSDLmain_a_SOURCES = $(MAINLIB_ARCH_SRCS)
    27 
    28 # Build an internal library of any special app setup functions
    29 noinst_LTLIBRARIES = libarch.la
    30 
    31 if TARGET_BEOS
    32 ARCH_SRCS = SDL_BeApp.cc SDL_BeApp.h
    33 else
    34 ARCH_SRCS = 
    35 endif
    36 
    37 # Include the architecture-independent sources
    38 COMMON_SRCS = dummy.c
    39 
    40 libarch_la_SOURCES = $(COMMON_SRCS) $(ARCH_SRCS)
    41 
    42 ## Let automake know that it shouldn't distribute linked sources
    43 BUILT_SOURCES = $(MAINLIB_ARCH_SRCS) $(ARCH_SRCS)
    44 
    45 ## Let automake know that it should remove these for distribution
    46 DISTCLEANFILES = $(MAINLIB_ARCH_SRCS) $(ARCH_SRCS)
    47 
    48 # The architecture specific directories need to be copied into place
    49 # when building a distribution.
    50 dist-hook:
    51 	(cd $(distdir) && rm -f $(BUILT_SOURCES))
    52 	cp -rp $(ARCH_SUBDIRS) $(distdir)
    53 	(cd $(distdir) && rm -rf `find . -name CVS`)