haiku/build/jam/packages/HaikuCrossDevel
Oliver Tappe eeddc9fd26 Fix paths in haiku_cross_devel packages.
* since this is now meant to be installed into an architecture-specific
  (sysroot-)folder, we need to drop the architecture-specific subpaths
2013-06-04 14:25:34 +02:00

75 lines
2.5 KiB
Plaintext

# This package is like the HaikuDevel package, but it is meant for cross
# development, i.e. it assumes that a specific cross compiler is installed
# on the Haiku system where this package is being used.
# The main use of this package is to provide HaikuPorter with a development
# environment for a cross-build Haiku platform.
# first create the actual cross development package
local haikuCrossDevelPackage = haiku_cross_devel_$(HAIKU_PACKAGING_ARCH).hpkg ;
HaikuPackage $(haikuCrossDevelPackage) ;
local developCrossLibDirTokens = develop lib ;
# glue code
AddFilesToPackage $(developCrossLibDirTokens) :
<src!system!glue!arch!$(TARGET_ARCH)>crti.o
<src!system!glue!arch!$(TARGET_ARCH)>crtn.o
<src!system!glue>init_term_dyn.o
<src!system!glue>start_dyn.o
<src!system!glue>haiku_version_glue.o
;
# kernel
AddFilesToPackage $(developCrossLibDirTokens) : kernel.so : _KERNEL_ ;
# libraries
AddLibrariesToPackage $(developCrossLibDirTokens) :
<revisioned>libroot.so
$(HAIKU_SHARED_LIBSTDC++) $(HAIKU_SHARED_LIBSUPC++)
;
# static libraries
AddFilesToPackage $(developCrossLibDirTokens) : liblocalestub.a ;
# the POSIX error code mapper library
AddFilesToPackage $(developCrossLibDirTokens) : libposix_error_mapper.a ;
# headers
local developCrossHeadersDirTokens = develop headers ;
local headerDir ;
for headerDir in config glibc os posix {
CopyDirectoryToPackage $(developCrossHeadersDirTokens)
: [ FDirName $(HAIKU_TOP) headers $(headerDir) ] ;
}
# BSD and GNU compatibility headers
for headerDir in bsd gnu {
CopyDirectoryToPackage $(developCrossHeadersDirTokens)
: [ FDirName $(HAIKU_TOP) headers compatibility $(headerDir) ] ;
}
# cpp headers
if $(HAIKU_GCC_VERSION[1]) = 2 {
# GCC 2 only -- for GCC 4 they come with the DevelopmentBase package
CopyDirectoryToPackage $(developCrossHeadersDirTokens) c++
: [ FDirName $(HAIKU_TOP) headers cpp ] : 2.95.3 ;
}
BuildHaikuPackage $(haikuCrossDevelPackage) : haiku_cross_devel ;
# Now create a wrapper package which just contains the actual cross development
# package. This wrapper package can safely be installed into the system
# hierarchy of the target system, from where haikuporter will fetch it when
# needed.
local haikuCrossDevelWrapperPackage
= haiku_cross_devel_wrapper_$(HAIKU_PACKAGING_ARCH).hpkg ;
HaikuPackage $(haikuCrossDevelWrapperPackage) ;
# add the wrapped package
local developCrossDirTokens = develop cross ;
AddFilesToPackage $(developCrossDirTokens) : $(haikuCrossDevelPackage) ;
BuildHaikuPackage $(haikuCrossDevelWrapperPackage) : haiku_cross_devel_wrapper ;