VirtualBox

source: vbox/trunk/src/VBox/Frontends/VBoxSDL/Makefile@ 649

Last change on this file since 649 was 614, checked in by vboxsync, 18 years ago

Darwin port (hope I didn't mess up anything, am very Zzzzz...)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.8 KB
Line 
1#
2# Makefile for VBoxSDL (a simple frontend based on SDL).
3#
4
5#
6# Copyright (C) 2006 InnoTek Systemberatung GmbH
7#
8# This file is part of VirtualBox Open Source Edition (OSE), as
9# available from http://www.virtualbox.org. This file is free software;
10# you can redistribute it and/or modify it under the terms of the GNU
11# General Public License as published by the Free Software Foundation,
12# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
13# distribution. VirtualBox OSE is distributed in the hope that it will
14# be useful, but WITHOUT ANY WARRANTY of any kind.
15#
16# If you received this file as part of a commercial VirtualBox
17# distribution, then only the terms of your commercial VirtualBox
18# license agreement apply instead of the previous paragraph.
19#
20
21DEPTH = ../../../..
22include $(PATH_KBUILD)/header.kmk
23
24PROGRAMS = VBoxSDL tstSDL
25
26
27#
28# VBoxSDL
29#
30ifneq ($(filter win linux,$(BUILD_TARGET)),) ## @todo Convert these two to the other template too!
31 VBoxSDL_TEMPLATE = VBOXR3NPEXE
32 VBoxSDL_CXXFLAGS.win = \
33 -EHsc
34 VBoxSDL_CXXFLAGS.linux = \
35 -DNDEBUG -DTRIMMED -DVBOX_WITH_XPCOM -O -Wall -fno-rtti -fno-exceptions \
36 -Wno-non-virtual-dtor -Wno-long-long -fshort-wchar -pthread -pipe
37else
38 VBoxSDL_TEMPLATE = VBOXMAINCLIENT
39endif
40VBoxSDL_SDKS = LIBSDL
41VBoxSDL_SOURCES = \
42 VBoxSDL.cpp \
43 Framebuffer.cpp \
44 Helper.cpp
45ifndef VBOX_OSE
46 VBoxSDL_SOURCES.win= \
47 win32/WinUI.cpp \
48 win32/TitlebarButtons.cpp \
49 win32/VBoxSDL.rc
50endif
51VBoxSDL_DEFS =
52ifdef VBOX_WITH_SECURELABEL
53 VBoxSDL_DEFS += VBOX_SECURELABEL
54endif
55ifdef VBOX_WITH_VRDP
56 VBoxSDL_DEFS += VBOX_VRDP
57endif
58VBoxSDL_DEFS.linux = _GNU_SOURCE
59ifdef VBOX_OPENGL
60 #VBoxSDL_DEFS.linux += VBOX_OPENGL
61endif
62ifndef VBOX_OSE
63 VBoxSDL_DEFS.win = VBOX_WIN32_UI
64endif
65VBoxSDL_DEFS.win.x86 = _WIN32_WINNT=0x0500
66VBoxSDL_DEFS.win.amd64 = _WIN32_WINNT=0x0510
67VBoxSDL_INCS = \
68 $(PATH_BIN)/sdk/include
69ifdef VBOX_WITH_XPCOM
70 VBoxSDL_INCS = \
71 $(PATH_BIN)/sdk/include \
72 $(VBOX_XPCOM_INCS) \
73 $(PATH_VBoxSDL)
74 VBoxSDL_LIBS = \
75 $(LIB_SDK_LIBSDL_SDLMAIN) \
76 $(PATH_LIB)/VBoxXPCOM$(VBOX_SUFF_LIB) \
77 $(LIB_RUNTIME) \
78 $(PATH_LIB)/VBoxXPCOMGlue$(VBOX_SUFF_LIB) \
79 $(PATH_BIN)/VBoxXPCOM$(VBOX_SUFF_DLL)
80 VBoxSDL_LIBS.linux = \
81 $(LIB_UUID) \
82 $(LIB_XCURSOR)
83 VBoxSDL_LDFLAGS.darwin = \
84 -framework Foundation -framework AppKit
85else # !VBOX_WITH_XPCOM
86 VBoxSDL_INCS.win = \
87 $(PATH_BIN)/sdk/include \
88 $(PATH_TOOL_$(VBOX_VCC_TOOL)_ATLMFC_INC) \
89 $(PATH_VBoxSDL)
90 VBoxSDL_LIBS.win = \
91 $(PATH_LIB)/VBoxCOM$(VBOX_SUFF_LIB) \
92 $(PATH_TOOL_$(VBOX_VCC_TOOL)_ATLMFC_LIB)/atls.lib \
93 $(LIB_RUNTIME)
94endif # !VBOX_WITH_XPCOM
95ifdef VBOX_OPENGL
96 #VBoxSDL_LIBS.linux += GL
97endif
98VBoxSDL_LIBPATH.linux = \
99 /usr/X11R6/lib
100
101VBoxSDL_CLEAN = $(PATH_VBoxSDL)/Ico64x01.h
102Framebuffer.cpp_DEPS = $(PATH_VBoxSDL)/Ico64x01.h
103
104
105#
106# tstSDL
107#
108tstSDL_TEMPLATE = VBOXR3NPEXE
109tstSDL_SDKS = LIBSDL
110tstSDL_INST = $(INST_TESTCASE)
111tstSDL_SOURCES = \
112 VBoxSDLTest.cpp
113tstSDL_DEFS = IN_RING3 IN_RT_R3 _GNU_SOURCE
114tstSDL_DEFS.win.x86 = _WIN32_WINNT=0x0500
115ifdef VBOX_OPENGL
116tstSDL_DEFS.linux = VBOX_OPENGL
117endif
118tstSDL_INCS = \
119 $(PATH_tstSDL)
120
121tstSDL_LIBS = \
122 $(LIB_RUNTIME)
123ifneq ($(filter-out win,$(BUILD_TARGET)),) # someone PLEASE explain why we don't use sdl main!
124tstSDL_LIBS += \
125 $(LIB_SDK_LIBSDL_SDLMAIN)
126endif
127ifdef VBOX_OPENGL
128tstSDL_LIBS.linux += GL
129endif
130tstSDL_LIBPATH.linux = \
131 /usr/X11R6/lib
132tstSDL_LDFLAGS.darwin = \
133 -framework Foundation -framework AppKit
134
135tstSDL_CXXFLAGS.win = \
136 -EHsc
137tstSDL_CXXFLAGS.linux = \
138 -DNDEBUG -DTRIMMED -O -Wall -fno-rtti -fno-exceptions \
139 -Wno-non-virtual-dtor -Wno-long-long -fshort-wchar -pthread -pipe
140
141
142# generate rules
143include $(PATH_KBUILD)/footer.kmk
144
145
146# Convert the pnm-file to a byte array.
147$(PATH_VBoxSDL)/Ico64x01.h: ico64x01.pnm $(VBOX_BIN2C) | $(call DIRDEP,$(PATH_VBoxSDL))
148 $(call MSG_L1,bin2c $< => $@)
149 $(QUIET)$(VBOX_BIN2C) Ico64x01 $< $@
150
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette