Fixed build of libgame.so on TARGET_PLATFORM= dano or r5 so now
we can build MediaKit (which requires replacing libgame.so) for targets haiku, r5 and dano. For building on Zeta, use platform dano. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13459 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -7,6 +7,10 @@
|
|||||||
* Distributed under the terms of the MIT License.
|
* Distributed under the terms of the MIT License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifdef COMPILE_FOR_R5
|
||||||
|
#include "/boot/develop/headers/be/interface/Window.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <DirectWindow.h>
|
#include <DirectWindow.h>
|
||||||
#include <clipping.h>
|
#include <clipping.h>
|
||||||
|
|
||||||
@@ -15,6 +19,12 @@
|
|||||||
#include <R5_Session.h>
|
#include <R5_Session.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// Compiling for DANO/Zeta is broken as it doesn't have BRegion::set_size()
|
||||||
|
#ifdef COMPILE_FOR_DANO
|
||||||
|
#warning "##### Bilding BDirectWindow for TARGET_PLATFORM=dano (DANO/Zeta) is broken #####"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// TODO: We'll want to move this to a private header,
|
// TODO: We'll want to move this to a private header,
|
||||||
// accessible by the app server.
|
// accessible by the app server.
|
||||||
struct dw_sync_data
|
struct dw_sync_data
|
||||||
@@ -253,7 +263,8 @@ BDirectWindow::GetClippingRegion(BRegion *region, BPoint *origin) const
|
|||||||
originX = (int32)origin->x;
|
originX = (int32)origin->x;
|
||||||
originY = (int32)origin->y;
|
originY = (int32)origin->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef COMPILE_FOR_DANO
|
||||||
// Since we are friend of BRegion, we can access its private members.
|
// Since we are friend of BRegion, we can access its private members.
|
||||||
// Otherwise, we would need to call BRegion::Include(clipping_rect)
|
// Otherwise, we would need to call BRegion::Include(clipping_rect)
|
||||||
// for every clipping_rect in our clip_list, and that would be much
|
// for every clipping_rect in our clip_list, and that would be much
|
||||||
@@ -270,6 +281,8 @@ BDirectWindow::GetClippingRegion(BRegion *region, BPoint *origin) const
|
|||||||
offset_rect(region->data[c], -originX, -originY);
|
offset_rect(region->data[c], -originX, -originY);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
UnlockDirect();
|
UnlockDirect();
|
||||||
|
|
||||||
return B_OK;
|
return B_OK;
|
||||||
|
|||||||
+15
-9
@@ -4,12 +4,11 @@ UsePrivateHeaders interface ;
|
|||||||
UsePrivateHeaders input ;
|
UsePrivateHeaders input ;
|
||||||
|
|
||||||
if ! $(HAIKU_COMPATIBLE) {
|
if ! $(HAIKU_COMPATIBLE) {
|
||||||
SubDirC++Flags -DCOMPILE_FOR_R5 ;
|
if $(DANO_COMPATIBLE) {
|
||||||
|
SubDirC++Flags -DCOMPILE_FOR_DANO ;
|
||||||
# Hack to have DirectWindow.cpp and WindowScreen.cpp
|
} else {
|
||||||
# include the R5 <Window .h> header.
|
SubDirC++Flags -DCOMPILE_FOR_R5 ;
|
||||||
PrependObjectHdrs DirectWindow.cpp : /boot/develop/headers/be/interface ;
|
}
|
||||||
PrependObjectHdrs WindowScreen.cpp : /boot/develop/headers/be/interface ;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -31,9 +30,16 @@ SharedLibrary game :
|
|||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
LinkSharedOSLibs libgame.so :
|
if $(HAIKU_COMPATIBLE) {
|
||||||
be libmedia.so
|
LinkSharedOSLibs libgame.so :
|
||||||
;
|
libbe.so libmedia.so
|
||||||
|
;
|
||||||
|
} else {
|
||||||
|
LinkSharedOSLibs libgame.so :
|
||||||
|
be libmedia.so
|
||||||
|
;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
MakeLocate <develop>libgame.so : $(OBOS_STLIB_DIR) ;
|
MakeLocate <develop>libgame.so : $(OBOS_STLIB_DIR) ;
|
||||||
RelSymLink <develop>libgame.so : libgame.so ;
|
RelSymLink <develop>libgame.so : libgame.so ;
|
||||||
|
|||||||
@@ -7,6 +7,10 @@
|
|||||||
* Distributed under the terms of the MIT License.
|
* Distributed under the terms of the MIT License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifdef COMPILE_FOR_R5
|
||||||
|
#include "/boot/develop/headers/be/interface/Window.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <Application.h>
|
#include <Application.h>
|
||||||
#include <Screen.h>
|
#include <Screen.h>
|
||||||
#include <WindowScreen.h>
|
#include <WindowScreen.h>
|
||||||
|
|||||||
Reference in New Issue
Block a user