Get a proper bootcd for unix builds (3rd stage.)
Thanks to Amine for his findings.


svn path=/branches/cmake-bringup/; revision=50338
This commit is contained in:
Sylvain Petreolle 2011-01-08 23:25:58 +00:00
parent f8f7ec4d56
commit acf11aa2c7

View file

@ -9,6 +9,9 @@ foreach(ENTRY ${CAB_TARGET_ENTRIES})
string(REGEX REPLACE "^(.*)\t.*" "\\1" _targetname ${ENTRY})
string(REGEX REPLACE "^.*\t(.)" "\\1" _dir_num ${ENTRY})
get_target_property(_FILENAME ${_targetname} LOCATION)
if(NOT CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
set(_FILENAME '\"${_FILENAME}\"')
endif()
add_custom_command(
OUTPUT ${REACTOS_BINARY_DIR}/boot/reactos.dff
COMMAND ${CMAKE_COMMAND} -E echo ${_FILENAME} ${_dir_num} >> ${REACTOS_BINARY_DIR}/boot/reactos.dff
@ -20,9 +23,14 @@ file(STRINGS ${REACTOS_BINARY_DIR}/boot/ros_cab.txt CAB_TARGET_ENTRIES)
foreach(ENTRY ${CAB_TARGET_ENTRIES})
string(REGEX REPLACE "^(.*)\t.*" "\\1" _FILENAME ${ENTRY})
string(REGEX REPLACE "^.*\t(.)" "\\1" _dir_num ${ENTRY})
add_custom_command(
if(NOT CMAKE_HOST_SYSTEM_NAME MATCHES Windows)
set(QUOTED_FILENAME '\"${_FILENAME}\"')
else()
set(QUOTED_FILENAME ${_FILENAME})
endif()
add_custom_command(
OUTPUT ${REACTOS_BINARY_DIR}/boot/reactos.dff
COMMAND ${CMAKE_COMMAND} -E echo ${_FILENAME} ${_dir_num} >> ${REACTOS_BINARY_DIR}/boot/reactos.dff
COMMAND ${CMAKE_COMMAND} -E echo ${QUOTED_FILENAME} ${_dir_num} >> ${REACTOS_BINARY_DIR}/boot/reactos.dff
DEPENDS ${_FILENAME}
APPEND)
endforeach()
@ -30,11 +38,11 @@ endforeach()
#reactos.cab
add_custom_command(
OUTPUT ${REACTOS_BINARY_DIR}/boot/reactos.inf
COMMAND native-cabman -C ${REACTOS_BINARY_DIR}/boot/reactos.dff -L ${REACTOS_BINARY_DIR}/boot -I
COMMAND native-cabman -C ${REACTOS_BINARY_DIR}/boot/reactos.dff -L ${REACTOS_BINARY_DIR}/boot -I -P ${REACTOS_SOURCE_DIR}
DEPENDS ${REACTOS_BINARY_DIR}/boot/reactos.dff)
add_custom_command(
OUTPUT ${REACTOS_BINARY_DIR}/boot/reactos.cab
COMMAND native-cabman -C ${REACTOS_BINARY_DIR}/boot/reactos.dff -RC ${REACTOS_BINARY_DIR}/boot/reactos.inf -L ${REACTOS_BINARY_DIR}/boot -N
COMMAND native-cabman -C ${REACTOS_BINARY_DIR}/boot/reactos.dff -RC ${REACTOS_BINARY_DIR}/boot/reactos.inf -L ${REACTOS_BINARY_DIR}/boot -N -P ${REACTOS_SOURCE_DIR}
DEPENDS ${REACTOS_BINARY_DIR}/boot/reactos.inf)
#bootcd target
@ -148,4 +156,4 @@ add_custom_target(livecd
DEPENDS ${LIVECD_FILES})
add_dependencies(livecd isoboot livecd_hives vgafonts)
set_directory_properties(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${REACTOS_BINARY_DIR}/livecd.iso)
set_directory_properties(DIRECTORY APPEND PROPERTY ADDITIONAL_MAKE_CLEAN_FILES ${REACTOS_BINARY_DIR}/livecd.iso)