Home | History | Annotate | Download | only in clang-include
      1 set(files
      2   altivec.h
      3   ammintrin.h
      4   arm_acle.h
      5   avxintrin.h
      6   avx2intrin.h
      7   bmiintrin.h
      8   bmi2intrin.h
      9   emmintrin.h
     10   f16cintrin.h
     11   float.h
     12   fma4intrin.h
     13   fmaintrin.h
     14   ia32intrin.h
     15   immintrin.h
     16   iso646.h
     17   Intrin.h
     18   limits.h
     19   lzcntintrin.h
     20   mm3dnow.h
     21   mmintrin.h
     22   mm_malloc.h
     23   nmmintrin.h
     24   pmmintrin.h
     25   popcntintrin.h
     26   prfchwintrin.h
     27   rdseedintrin.h
     28   rtmintrin.h
     29   shaintrin.h
     30   smmintrin.h
     31   stdalign.h
     32   stdarg.h
     33   stdbool.h
     34   stddef.h
     35   stdint.h
     36   stdnoreturn.h
     37   tbmintrin.h
     38   tgmath.h
     39   tmmintrin.h
     40   varargs.h
     41   wmmintrin.h
     42   __wmmintrin_aes.h
     43   __wmmintrin_pclmul.h
     44   x86intrin.h
     45   xmmintrin.h
     46   xopintrin.h
     47   cpuid.h
     48   unwind.h
     49   module.modulemap
     50   )
     51 
     52 set(output_dir ${LLVM_LIBRARY_OUTPUT_INTDIR}/clang/${CLANG_VERSION}/include)
     53 
     54 # Generate arm_neon.h
     55 clang_tablegen(arm_neon.h -gen-arm-neon
     56   SOURCE ${CLANG_SOURCE_DIR}/include/clang/Basic/arm_neon.td)
     57 
     58 set(out_files)
     59 foreach( f ${files} )
     60   set( src ${CMAKE_CURRENT_SOURCE_DIR}/${f} )
     61   set( dst ${output_dir}/${f} )
     62   add_custom_command(OUTPUT ${dst}
     63     DEPENDS ${src}
     64     COMMAND ${CMAKE_COMMAND} -E copy_if_different ${src} ${dst}
     65     COMMENT "Copying clang's ${f}...")
     66   list(APPEND out_files ${dst})
     67 endforeach( f )
     68 
     69 add_custom_command(OUTPUT ${output_dir}/arm_neon.h 
     70   DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/arm_neon.h
     71   COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_BINARY_DIR}/arm_neon.h ${output_dir}/arm_neon.h
     72   COMMENT "Copying clang's arm_neon.h...")
     73 list(APPEND out_files ${output_dir}/arm_neon.h)
     74 
     75 add_custom_target(clang-headers ALL DEPENDS ${out_files})
     76 set_target_properties(clang-headers PROPERTIES FOLDER "Misc")
     77 
     78 install(
     79   FILES ${files} ${CMAKE_CURRENT_BINARY_DIR}/arm_neon.h
     80   PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
     81   DESTINATION lib${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION}/include)
     82