Support building more libraries for secondary architecture
This commit is contained in:
@@ -2,12 +2,17 @@ SubDir HAIKU_TOP src add-ons translators exr openexr half ;
|
||||
|
||||
SubDirSysHdrs [ FDirName $(SUBDIR) ] ;
|
||||
|
||||
if $(TARGET_PACKAGING_ARCH) = x86_gcc2 {
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
if $(TARGET_PACKAGING_ARCH) = x86_gcc2 {
|
||||
SubDirC++Flags -Dios_base=ios -ftemplate-depth-24 ;
|
||||
}
|
||||
}
|
||||
|
||||
StaticLibrary libhalf.a :
|
||||
StaticLibrary [ MultiArchDefaultGristFiles libhalf.a ] :
|
||||
eLut.cpp
|
||||
half.cpp
|
||||
toFloat.cpp
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,8 +2,12 @@ SubDir HAIKU_TOP src add-ons translators exr openexr iex ;
|
||||
|
||||
SubDirSysHdrs [ FDirName $(SUBDIR) ] ;
|
||||
|
||||
StaticLibrary libiex.a :
|
||||
IexBaseExc.cpp
|
||||
IexThrowErrnoExc.cpp
|
||||
;
|
||||
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
StaticLibrary [ MultiArchDefaultGristFiles libiex.a ] :
|
||||
IexBaseExc.cpp
|
||||
IexThrowErrnoExc.cpp
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,17 +7,20 @@ SubDirSysHdrs [ FDirName $(SUBDIR) $(DOTDOT) ilmthread ] ;
|
||||
SubDirSysHdrs [ FDirName $(SUBDIR) $(DOTDOT) imath ] ;
|
||||
SubDirHdrs [ FDirName $(SUBDIR) $(DOTDOT) config ] ;
|
||||
|
||||
if $(TARGET_PACKAGING_ARCH) = x86_gcc2 {
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
UseBuildFeatureHeaders zlib ;
|
||||
|
||||
if $(TARGET_PACKAGING_ARCH) = x86_gcc2 {
|
||||
SubDirC++Flags -Dios_base=ios -ftemplate-depth-24 ;
|
||||
}
|
||||
}
|
||||
|
||||
UseBuildFeatureHeaders zlib ;
|
||||
|
||||
Includes [ FGristFiles ImfPxr24Compressor.cpp ImfZipCompressor.cpp ]
|
||||
Includes [ FGristFiles ImfPxr24Compressor.cpp ImfZipCompressor.cpp ]
|
||||
: [ BuildFeatureAttribute zlib : headers ] ;
|
||||
|
||||
#StaticLibrary libilmimf.a :
|
||||
SharedLibrary libilmimf.so :
|
||||
#StaticLibrary [ MultiArchDefaultGristFiles libilmimf.a ] :
|
||||
SharedLibrary [ MultiArchDefaultGristFiles libilmimf.so ] :
|
||||
b44ExpLogTable.cpp
|
||||
ImfAttribute.cpp
|
||||
ImfB44Compressor.cpp
|
||||
@@ -76,7 +79,11 @@ SharedLibrary libilmimf.so :
|
||||
ImfVersion.cpp
|
||||
ImfWav.cpp
|
||||
ImfZipCompressor.cpp
|
||||
: libhalf.a libiex.a libimath.a libilmthread.a $(TARGET_LIBSTDC++)
|
||||
:
|
||||
[ MultiArchDefaultGristFiles libhalf.a libiex.a libimath.a
|
||||
libilmthread.a ]
|
||||
$(TARGET_LIBSTDC++)
|
||||
[ BuildFeatureAttribute zlib : library ]
|
||||
;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,13 +4,18 @@ SubDirSysHdrs [ FDirName $(SUBDIR) ] ;
|
||||
SubDirSysHdrs [ FDirName $(SUBDIR) $(DOTDOT) iex ] ;
|
||||
SubDirHdrs [ FDirName $(SUBDIR) $(DOTDOT) config ] ;
|
||||
|
||||
StaticLibrary libilmthread.a :
|
||||
IlmThread.cpp
|
||||
IlmThreadMutex.cpp
|
||||
IlmThreadMutexPosix.cpp
|
||||
IlmThreadPool.cpp
|
||||
IlmThreadPosix.cpp
|
||||
IlmThreadSemaphore.cpp
|
||||
IlmThreadSemaphorePosixCompat.cpp
|
||||
IlmThreadSemaphorePosix.cpp
|
||||
;
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
StaticLibrary [ MultiArchDefaultGristFiles libilmthread.a ] :
|
||||
IlmThread.cpp
|
||||
IlmThreadMutex.cpp
|
||||
IlmThreadMutexPosix.cpp
|
||||
IlmThreadPool.cpp
|
||||
IlmThreadPosix.cpp
|
||||
IlmThreadSemaphore.cpp
|
||||
IlmThreadSemaphorePosixCompat.cpp
|
||||
IlmThreadSemaphorePosix.cpp
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,11 +4,14 @@ SubDirSysHdrs [ FDirName $(SUBDIR) ] ;
|
||||
SubDirSysHdrs [ FDirName $(SUBDIR) $(DOTDOT) half ] ;
|
||||
SubDirSysHdrs [ FDirName $(SUBDIR) $(DOTDOT) iex ] ;
|
||||
|
||||
if $(TARGET_PACKAGING_ARCH) = x86_gcc2 {
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
if $(TARGET_PACKAGING_ARCH) = x86_gcc2 {
|
||||
SubDirC++Flags -Dios_base=ios -ftemplate-depth-24 ;
|
||||
}
|
||||
}
|
||||
|
||||
StaticLibrary libimath.a :
|
||||
StaticLibrary [ MultiArchDefaultGristFiles libimath.a ] :
|
||||
ImathBox.cpp
|
||||
ImathColorAlgo.cpp
|
||||
ImathFun.cpp
|
||||
@@ -17,3 +20,5 @@ StaticLibrary libimath.a :
|
||||
ImathShear.cpp
|
||||
ImathVec.cpp
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
+31
-22
@@ -2,11 +2,6 @@ SubDir HAIKU_TOP src kits opengl ;
|
||||
|
||||
SetSubDirSupportedPlatformsBeOSCompatible ;
|
||||
|
||||
UsePrivateHeaders interface ;
|
||||
UsePrivateSystemHeaders ;
|
||||
UseBuildFeatureHeaders glu ;
|
||||
UseBuildFeatureHeaders mesa ;
|
||||
|
||||
local sources =
|
||||
GLView.cpp
|
||||
GLDispatcher.cpp
|
||||
@@ -20,29 +15,41 @@ if $(TARGET_PLATFORM) != haiku {
|
||||
# We need our public GL headers also when not compiling for Haiku.
|
||||
}
|
||||
|
||||
Includes [ FGristFiles $(sources) ] : [ BuildFeatureAttribute glu : headers ] ;
|
||||
Includes [ FGristFiles $(sources) ] : [ BuildFeatureAttribute mesa : headers ] ;
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
local architecture = $(TARGET_PACKAGING_ARCH) ;
|
||||
|
||||
UseHeaders [ BuildFeatureAttribute mesa : headers : path ] ;
|
||||
local privateHeaders = [ BuildFeatureAttribute mesa : privateHeaders : path ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mesa ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mesa main ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mapi ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mapi glapi ] ;
|
||||
UsePrivateHeaders interface ;
|
||||
UsePrivateSystemHeaders ;
|
||||
UseBuildFeatureHeaders glu ;
|
||||
UseBuildFeatureHeaders mesa ;
|
||||
|
||||
# For older versions of Mesa
|
||||
UseHeaders [ FDirName $(privateHeaders) mesa glapi ] ;
|
||||
Includes [ FGristFiles $(sources) ]
|
||||
: [ BuildFeatureAttribute glu : headers ] ;
|
||||
Includes [ FGristFiles $(sources) ]
|
||||
: [ BuildFeatureAttribute mesa : headers ] ;
|
||||
|
||||
LINKFLAGS on libGL.so = [ on libGL.so return $(LINKFLAGS) ]
|
||||
UseHeaders [ BuildFeatureAttribute mesa : headers : path ] ;
|
||||
local privateHeaders
|
||||
= [ BuildFeatureAttribute mesa : privateHeaders : path ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mesa ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mesa main ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mapi ] ;
|
||||
UseHeaders [ FDirName $(privateHeaders) mapi glapi ] ;
|
||||
|
||||
# For older versions of Mesa
|
||||
UseHeaders [ FDirName $(privateHeaders) mesa glapi ] ;
|
||||
|
||||
LINKFLAGS on libGL.so = [ on libGL.so return $(LINKFLAGS) ]
|
||||
-Xlinker --whole-archive -Xlinker --no-undefined ;
|
||||
|
||||
# For GCC2
|
||||
if $(TARGET_GCC_VERSION_$(TARGET_PACKAGING_ARCH)[1]) < 3 {
|
||||
# For GCC2
|
||||
if $(architecture) = x86_gcc2 {
|
||||
SubDirC++Flags --no-warnings ;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
SharedLibrary libGL.so : $(sources) :
|
||||
SharedLibrary [ MultiArchDefaultGristFiles libGL.so ] : $(sources) :
|
||||
# GLU
|
||||
[ BuildFeatureAttribute glu : library ]
|
||||
|
||||
@@ -54,4 +61,6 @@ SharedLibrary libGL.so : $(sources) :
|
||||
network
|
||||
be
|
||||
$(TARGET_LIBSTDC++)
|
||||
;
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
+17
-10
@@ -1,6 +1,4 @@
|
||||
SubDir HAIKU_TOP src libs glut ;
|
||||
UseBuildFeatureHeaders glu ;
|
||||
UseBuildFeatureHeaders mesa ;
|
||||
|
||||
SetSubDirSupportedPlatformsBeOSCompatible ;
|
||||
|
||||
@@ -50,22 +48,31 @@ local sourcesCpp =
|
||||
;
|
||||
|
||||
|
||||
# For GCC2
|
||||
if $(TARGET_GCC_VERSION_$(TARGET_PACKAGING_ARCH)[1]) < 3 {
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
local architecture = $(TARGET_PACKAGING_ARCH) ;
|
||||
|
||||
UseBuildFeatureHeaders glu ;
|
||||
UseBuildFeatureHeaders mesa ;
|
||||
|
||||
# For GCC2
|
||||
if $(architecture) = x86_gcc2 {
|
||||
SubDirC++Flags --no-warnings ;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
# Ensure Mesa dependency is met
|
||||
Includes [ FGristFiles $(sourcesCc) $(sourcesCpp) ] :
|
||||
# Ensure Mesa dependency is met
|
||||
Includes [ FGristFiles $(sourcesCc) $(sourcesCpp) ] :
|
||||
[ BuildFeatureAttribute glu : headers ]
|
||||
[ BuildFeatureAttribute mesa : headers ]
|
||||
;
|
||||
|
||||
SharedLibrary libglut.so :
|
||||
SharedLibrary [ MultiArchDefaultGristFiles libglut.so ] :
|
||||
$(sourcesCpp)
|
||||
$(sourcesCc)
|
||||
:
|
||||
GL game be $(TARGET_LIBSTDC++)
|
||||
[ BuildFeatureAttribute glu : library ]
|
||||
;
|
||||
;
|
||||
}
|
||||
}
|
||||
|
||||
+16
-9
@@ -1,9 +1,5 @@
|
||||
SubDir HAIKU_TOP src libs tiff ;
|
||||
|
||||
UseLibraryHeaders tiff ;
|
||||
UseBuildFeatureHeaders jpeg ;
|
||||
UseBuildFeatureHeaders zlib ;
|
||||
|
||||
SubDirHdrs [ FDirName $(SUBDIR) $(DOTDOT) shared ] ;
|
||||
|
||||
local shared_files =
|
||||
@@ -46,17 +42,28 @@ local shared_files =
|
||||
tif_zip.c
|
||||
;
|
||||
|
||||
Includes [ FGristFiles tif_jpeg.c tif_ojpeg.c ]
|
||||
local architectureObject ;
|
||||
for architectureObject in [ MultiArchSubDirSetup ] {
|
||||
on $(architectureObject) {
|
||||
UseLibraryHeaders tiff ;
|
||||
UseBuildFeatureHeaders jpeg ;
|
||||
UseBuildFeatureHeaders zlib ;
|
||||
|
||||
Includes [ FGristFiles tif_jpeg.c tif_ojpeg.c ]
|
||||
: [ BuildFeatureAttribute jpeg : headers ] ;
|
||||
Includes [ FGristFiles tif_pixarlog.c tif_zip.c ]
|
||||
Includes [ FGristFiles tif_pixarlog.c tif_zip.c ]
|
||||
: [ BuildFeatureAttribute zlib : headers ] ;
|
||||
|
||||
Objects $(shared_files) ;
|
||||
Objects $(shared_files) ;
|
||||
|
||||
SharedLibrary libtiff.so : [ FGristFiles $(shared_files:S=.o) ]
|
||||
SharedLibrary [ MultiArchDefaultGristFiles libtiff.so ]
|
||||
: [ FGristFiles $(shared_files:S=.o) ]
|
||||
:
|
||||
[ BuildFeatureAttribute jpeg : library ]
|
||||
[ BuildFeatureAttribute zlib : library ]
|
||||
: 3.8 ;
|
||||
|
||||
StaticLibrary libtiff.a : [ FGristFiles $(shared_files:S=.o) ] ;
|
||||
StaticLibrary [ MultiArchDefaultGristFiles libtiff.a ]
|
||||
: [ FGristFiles $(shared_files:S=.o) ] ;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user