macro(example nm)
    add_allegro_executable(${nm} ${nm}.c)
endmacro(example nm)

if(WANT_OLD_EXAMPLES)
    example(ex3buf)
    example(ex3d)
    example(ex12bit)
    example(exaccel)
    example(exalpha)
    example(exbitmap)
    example(exblend)
    example(excamera)
    example(excolmap)
    example(exconfig)
    example(excustom)
    example(exdata)
    example(exdbuf)
    example(exexedat)
    example(exfixed)
    example(exflame)
    example(exflip)
    example(exfont)
    example(exgui)
    example(exhello)
    example(exjoy)
    example(exkeys)
    example(exlights)
    example(exmem)
    example(exmidi)
    example(exmouse)
    example(expackf)
    example(expal)
    example(expat)
    example(exquat)
    example(exrgbhsv)
    example(exsample)
    example(exscale)
    example(exscn3d)
    example(exscroll)
    example(exshade)
    example(exspline)
    example(exsprite)
    example(exstars)
    example(exstream)
    example(exswitch)
    example(exsyscur)
    example(extimer)
    example(extrans)
    example(extruec)
    example(exunicod)
    example(exupdate)
    example(exxfade)
    example(exzbuf)
endif(WANT_OLD_EXAMPLES)

example(exnewapi)
example(exnew_bitmap)
example(exnew_fs_resize)
example(exnew_icon)
example(exnew_lockbitmap)
example(exnew_lockscreen)
example(exnew_mouse)
example(exnew_mouse_events)
example(exnew_resize)

if(WANT_FONT)
    include_directories(../addons/font)
    add_font_example(exnew_events exnew_events.c)
    add_font_example(exnew_membmp exnew_membmp.c)
    add_font_example(exnew_bitmap_target exnew_bitmap_target.c)
    add_font_example(exnew_blend exnew_blend.c)
endif(WANT_FONT)

if(WANT_D3D)
    if (USE_CXX)
        if(HAVE_D3DX9)
            macro(add_d3dx_example nm)
                add_executable(${nm} ${ARGN})
                set_target_properties(${nm} PROPERTIES
                    COMPILE_FLAGS "${MAYBE_ALLEGRO_STATICLINK}"
                    LINK_FLAGS "${MAYBE_ALLEGRO_STATICLINK}"
                    )
                target_link_libraries(${nm} ${LINK_WITH})
                target_link_libraries(${nm} d3dx9)
            endmacro(add_d3dx_example)

            add_d3dx_example(exnew_d3d exnew_d3d.cpp)
        endif(HAVE_D3DX9)
    endif(USE_CXX)
endif(WANT_D3D)

#-----------------------------------------------------------------------------#
# vi: set ts=8 sts=4 sw=4 et:
