[Beignet] [PATCH v2] GBE: fix relocatable issue for pch file.
Song, Ruiling
ruiling.song at intel.com
Tue Nov 11 00:54:00 PST 2014
> +ADD_CUSTOM_COMMAND(OUTPUT
> ${OCL_OBJECT_DIR}/beignet.local.pch
> + COMMAND mkdir -p ${OCL_OBJECT_DIR}
> + COMMAND ${LLVM_INSTALL_DIR}clang -cc1 ${CLANG_OCL_FLAGS}
> -triple spir -I ${OCL_OBJECT_DIR}/include/ -emit-pch -x cl
> ${OCL_OBJECT_DIR}/include/ocl.h -o ${OCL_OBJECT_DIR}/beignet.local.pch
> + DEPENDS ${OCL_HEADER_FILES}
> + COMMENT "Generate the pch file: ${OCL_OBJECT_DIR}/beignet.pch"
> + )
> +
> +ADD_CUSTOM_COMMAND(OUTPUT ${OCL_OBJECT_DIR}/beignet.pch
> + COMMAND mkdir -p ${OCL_OBJECT_DIR}
> + COMMAND ${LLVM_INSTALL_DIR}clang -cc1 ${CLANG_OCL_FLAGS}
> -triple
> +spir -I ${OCL_OBJECT_DIR}/include/ --relocatable-pch -emit-pch
> +-isysroot ${LIBOCL_BINARY_DIR} -x cl ${OCL_OBJECT_DIR}/include/ocl.h
> -o
> +${OCL_OBJECT_DIR}/beignet.pch
> DEPENDS ${OCL_HEADER_FILES}
> - COMMENT "Generate the pch file:
> ${LIBOCL_BINARY_DIR}/lib/beignet.pch"
> + COMMENT "Generate the pch file:
> ${OCL_OBJECT_DIR}/beignet.local.pch"
The comment above should be also ex-changed. Other part LGTM.
> )
>
> -add_custom_target(beignet_bitcode ALL DEPENDS
> ${LIBOCL_BINARY_DIR}/lib/beignet.bc
> ${LIBOCL_BINARY_DIR}/lib/beignet.pch)
> +
> +add_custom_target(beignet_bitcode ALL DEPENDS
> +${OCL_OBJECT_DIR}/beignet.bc ${OCL_OBJECT_DIR}/beignet.pch
> +${OCL_OBJECT_DIR}/beignet.local.pch)
> +SET (OCL_OBJECT_DIR ${OCL_OBJECT_DIR} PARENT_SCOPE) SET
> +(OCL_HEADER_FILES ${OCL_HEADER_FILES} PARENT_SCOPE)
> --
> 1.8.3.2
>
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet
More information about the Beignet
mailing list