[x265] [PATCH 3 of 4] cmake: use explicit file list for HM TLibEncoder files

Steve Borho steve at borho.org
Fri Sep 20 03:18:42 CEST 2013


# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1379638890 18000
#      Thu Sep 19 20:01:30 2013 -0500
# Node ID bd1d4bdc996e761d1cb7ac8ccbbdac9179cb7f1c
# Parent  00429bb81ef7e17247cb2d9f6b5470a7c536a9cd
cmake: use explicit file list for HM TLibEncoder files

This prevents issues when HM files are deleted; we simply remove them from this
list and then CMake automatically regenerates projects or Makefiles.  With
globs, you have to know to poke CMake to regenerate the files, but most do not
know this.

diff -r 00429bb81ef7 -r bd1d4bdc996e source/encoder/CMakeLists.txt
--- a/source/encoder/CMakeLists.txt	Thu Sep 19 19:53:49 2013 -0500
+++ b/source/encoder/CMakeLists.txt	Thu Sep 19 20:01:30 2013 -0500
@@ -10,10 +10,40 @@
     endif()
 endif(GCC)
 
-file(GLOB LIBENCODER_HDR  ../Lib/TLibEncoder/*.h)
-file(GLOB LIBENCODER_SRC  ../Lib/TLibEncoder/*.cpp)
+set(LIBENCODER_HDR
+    ../Lib/TLibEncoder/NALwrite.h
+    ../Lib/TLibEncoder/SEIwrite.h
+    ../Lib/TLibEncoder/SyntaxElementWriter.h
+    ../Lib/TLibEncoder/TEncAnalyze.h
+    ../Lib/TLibEncoder/TEncBinCoder.h
+    ../Lib/TLibEncoder/TEncBinCoderCABAC.h
+    ../Lib/TLibEncoder/TEncBinCoderCABACCounter.h
+    ../Lib/TLibEncoder/TEncCavlc.h
+    ../Lib/TLibEncoder/TEncCfg.h
+    ../Lib/TLibEncoder/TEncCu.h
+    ../Lib/TLibEncoder/TEncEntropy.h
+    ../Lib/TLibEncoder/TEncSampleAdaptiveOffset.h
+    ../Lib/TLibEncoder/TEncSbac.h
+    ../Lib/TLibEncoder/TEncSearch.h
+    ../Lib/TLibEncoder/TEncTop.h
+    ../Lib/TLibEncoder/WeightPredAnalysis.h)
+set(LIBENCODER_SRC
+    ../Lib/TLibEncoder/NALwrite.cpp
+    ../Lib/TLibEncoder/SEIwrite.cpp
+    ../Lib/TLibEncoder/SyntaxElementWriter.cpp
+    ../Lib/TLibEncoder/TEncBinCoderCABAC.cpp
+    ../Lib/TLibEncoder/TEncBinCoderCABACCounter.cpp
+    ../Lib/TLibEncoder/TEncCavlc.cpp
+    ../Lib/TLibEncoder/TEncCu.cpp
+    ../Lib/TLibEncoder/TEncEntropy.cpp
+    ../Lib/TLibEncoder/TEncSampleAdaptiveOffset.cpp
+    ../Lib/TLibEncoder/TEncSbac.cpp
+    ../Lib/TLibEncoder/TEncSearch.cpp
+    ../Lib/TLibEncoder/TEncTop.cpp
+    ../Lib/TLibEncoder/WeightPredAnalysis.cpp)
 source_group(TLibEncoder FILES ${LIBENCODER_SRC})
 source_group(TLibEncoderH FILES ${LIBENCODER_HDR})
+
 if(GCC)
     set_source_files_properties(compress.cpp ${LIBENCODER_SRC} PROPERTIES COMPILE_FLAGS 
         "-Wno-sign-compare")


More information about the x265-devel mailing list