mirror of
https://github.com/json-c/json-c.git
synced 2026-11-09 23:40:14 +08:00
Package for Amiga for publishing
This commit is contained in:
1 parent
a52110770c
commit
3ea3271978
6 files changed
+397
-1
No files matched your search
+37
-1
@@ -126,9 +126,45 @@ if (AMIGA)
|
||||
endif()
|
||||
elseif ($ENV{CROSS_PFX} STREQUAL "ppc-amigaos")
|
||||
set(AMIGA_PPC ON)
|
||||
message(STATUS "Building for PowerPC AmigaOS")
|
||||
if (NOT DEFINED PPC_CRT)
|
||||
set(PPC_CRT "newlib")
|
||||
endif()
|
||||
set(PPC_CRT "${PPC_CRT}" CACHE STRING "ppc-amigaos C runtime: newlib, clib2 or clib4")
|
||||
set_property(CACHE PPC_CRT PROPERTY STRINGS newlib clib2 clib4)
|
||||
if (NOT PPC_CRT STREQUAL "newlib" AND
|
||||
NOT PPC_CRT STREQUAL "clib2" AND
|
||||
NOT PPC_CRT STREQUAL "clib4")
|
||||
message(FATAL_ERROR "PPC_CRT must be newlib, clib2 or clib4 (got: ${PPC_CRT})")
|
||||
endif()
|
||||
if (NOT PPC_CRT STREQUAL "newlib")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mcrt=${PPC_CRT}")
|
||||
endif()
|
||||
message(STATUS "Building for PowerPC AmigaOS using CRT: ${PPC_CRT}")
|
||||
elseif($ENV{CROSS_PFX} STREQUAL "ppc-morphos")
|
||||
set(MORPHOS ON)
|
||||
if (NOT DEFINED MORPHOS_CLIB)
|
||||
set(MORPHOS_CLIB "default")
|
||||
endif()
|
||||
set(MORPHOS_CLIB "${MORPHOS_CLIB}" CACHE STRING "MorphOS C library: default or libnix")
|
||||
set_property(CACHE MORPHOS_CLIB PROPERTY STRINGS default libnix)
|
||||
if (NOT MORPHOS_CLIB STREQUAL "default" AND NOT MORPHOS_CLIB STREQUAL "libnix")
|
||||
message(FATAL_ERROR "MORPHOS_CLIB must be default or libnix (got: ${MORPHOS_CLIB})")
|
||||
endif()
|
||||
option(MORPHOS_BASEREL32 "MorphOS: build with -mbaserel32" OFF)
|
||||
if (MORPHOS_CLIB STREQUAL "libnix")
|
||||
# Same situation as the -noixemul path below: libnix's headers
|
||||
# disagree with the ixemul ones about va_list, so the varargs
|
||||
# helpers in debug.c trip -Wincompatible-pointer-types.
|
||||
set(DISABLE_WERROR ON)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-incompatible-pointer-types")
|
||||
endif()
|
||||
if (MORPHOS_CLIB STREQUAL "libnix")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mclib=libnix")
|
||||
endif()
|
||||
if (MORPHOS_BASEREL32)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mbaserel32")
|
||||
endif()
|
||||
message(STATUS "Building for PowerPC MorphOS using clib: ${MORPHOS_CLIB}, baserel32: ${MORPHOS_BASEREL32}")
|
||||
if (NOIXEMUL)
|
||||
message(STATUS "Building for PowerPC MorphOS without ixemul")
|
||||
set(DISABLE_WERROR ON)
|
||||
|
||||
Reference in new issue
Block a user