cmake
authorCampbell Barton <ideasman42@gmail.com>
Mon, 2 Aug 2010 16:23:58 +0000 (16:23 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Mon, 2 Aug 2010 16:23:58 +0000 (16:23 +0000)
- more strict warnings for gcc/unix, still <50 for a clean build.
- install files to /usr/local/share/blender/2.53 rather then /usr/local/share/blender/.blender

CMakeLists.txt
build_files/cmake/macros.cmake
source/creator/CMakeLists.txt

index 0016f3de16183dc57e06731eca88e0f9bc5e2fc4..e249f25230051717ab8e481674eea0683e0a4e14 100644 (file)
@@ -323,8 +323,8 @@ IF(UNIX AND NOT APPLE)
        SET(PLATFORM_LINKFLAGS "-pthread")
 
        # Better warnings
-       SET(C_WARNINGS "-Wall -Wno-char-subscripts -Wpointer-arith -Wcast-align -Wdeclaration-after-statement -Wno-unknown-pragmas")
-       SET(CXX_WARNINGS "-Wall -Wno-invalid-offsetof -Wno-sign-compare")
+       SET(C_WARNINGS "-Wall -Wextra -Winit-self -Wno-unused-parameter -Wno-ignored-qualifiers -Wno-sign-compare -Wno-missing-field-initializers -Wno-char-subscripts -Wpointer-arith -Wcast-align -Wdeclaration-after-statement -Wno-unknown-pragmas")
+       SET(CXX_WARNINGS "-Wall -Wextra -Winit-self -Wno-unused-parameter -Wno-ignored-qualifiers -Wno-sign-compare -Wno-missing-field-initializers -Wno-invalid-offsetof -Wno-sign-compare")
 
        INCLUDE_DIRECTORIES(${JPEG_INCLUDE_DIR} ${PNG_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} )
 ENDIF(UNIX AND NOT APPLE)
index 84e6b788dc0906dfe2ceb1e24320ab06852874e6..1aa9ee3f62ead08e1d897b905537bd9fdd686a49 100644 (file)
@@ -198,6 +198,7 @@ MACRO(TEST_SSE_SUPPORT)
        SUPPORT_SSE_BUILD)
 ENDMACRO(TEST_SSE_SUPPORT)
 
+
 MACRO(GET_BLENDER_VERSION)
        FILE(READ ${CMAKE_SOURCE_DIR}/source/blender/blenkernel/BKE_blender.h CONTENT)
        STRING(REGEX REPLACE "\n" ";" CONTENT "${CONTENT}")
index a653d45bd14e0b09bd57d545e2fbeb12ea86e8f7..72e48c0893e4506446cfd3d84e0371e839a4206e 100644 (file)
@@ -123,16 +123,16 @@ IF(WITH_INSTALL)
                
                ADD_CUSTOM_COMMAND(
                        TARGET blender POST_BUILD MAIN_DEPENDENCY blender
-                       COMMAND rm -Rf ${TARGETDIR}/.blender
-                       COMMAND mkdir ${TARGETDIR}/.blender/
-                       COMMAND cp ${CMAKE_SOURCE_DIR}/release/bin/.blender/.bfont.ttf ${TARGETDIR}/.blender/
+                       COMMAND rm -Rf ${TARGETDIR}/${BLENDER_VERSION}
+                       COMMAND mkdir ${TARGETDIR}/${BLENDER_VERSION}/
+                       COMMAND cp ${CMAKE_SOURCE_DIR}/release/bin/.blender/.bfont.ttf ${TARGETDIR}/${BLENDER_VERSION}/
                )
     
                IF(WITH_INTERNATIONAL)
                        ADD_CUSTOM_COMMAND(
                                TARGET blender POST_BUILD MAIN_DEPENDENCY blender
-                               COMMAND cp ${CMAKE_SOURCE_DIR}/release/bin/.blender/.Blanguages ${TARGETDIR}/.blender/
-                               COMMAND cp -R ${CMAKE_SOURCE_DIR}/release/bin/.blender/locale ${TARGETDIR}/.blender/
+                               COMMAND cp ${CMAKE_SOURCE_DIR}/release/bin/.blender/.Blanguages ${TARGETDIR}/${BLENDER_VERSION}/
+                               COMMAND cp -R ${CMAKE_SOURCE_DIR}/release/bin/.blender/locale ${TARGETDIR}/${BLENDER_VERSION}/
                        )
                ENDIF(WITH_INTERNATIONAL)
     
@@ -140,7 +140,7 @@ IF(WITH_INSTALL)
                        ADD_CUSTOM_COMMAND(
                                TARGET blender POST_BUILD MAIN_DEPENDENCY blender
                                COMMENT "copying blender scripts..."
-                               COMMAND cp -R ${CMAKE_SOURCE_DIR}/release/scripts ${TARGETDIR}/.blender/
+                               COMMAND cp -R ${CMAKE_SOURCE_DIR}/release/scripts ${TARGETDIR}/${BLENDER_VERSION}/
                                COMMAND find ${TARGETDIR} -name "*.py?" -prune -exec rm -rf {} "\;"
                        )
                        IF(WITH_PYTHON_INSTALL)
@@ -150,23 +150,23 @@ IF(WITH_INSTALL)
                                        TARGET blender POST_BUILD MAIN_DEPENDENCY blender
                                        COMMENT "copying a subset of the systems python..."
 
-                                       COMMAND mkdir ${TARGETDIR}/.blender/python # PYTHONPATH and PYTHONHOME is set here
-                                       COMMAND mkdir ${TARGETDIR}/.blender/python/lib/
-                                       COMMAND cp -R ${PYTHON_LIBPATH}/python${PYTHON_VERSION} ${TARGETDIR}/.blender/python/lib/
+                                       COMMAND mkdir ${TARGETDIR}/${BLENDER_VERSION}/python # PYTHONPATH and PYTHONHOME is set here
+                                       COMMAND mkdir ${TARGETDIR}/${BLENDER_VERSION}/python/lib/
+                                       COMMAND cp -R ${PYTHON_LIBPATH}/python${PYTHON_VERSION} ${TARGETDIR}/${BLENDER_VERSION}/python/lib/
 
-                                       COMMAND rm -rf ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/distutils
-                                       COMMAND rm -rf ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/lib2to3
-                                       COMMAND rm -rf ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/idlelib
-                                       COMMAND rm -rf ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/tkinter
-                                       COMMAND rm -rf ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/config
+                                       COMMAND rm -rf ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/distutils
+                                       COMMAND rm -rf ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/lib2to3
+                                       COMMAND rm -rf ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/idlelib
+                                       COMMAND rm -rf ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/tkinter
+                                       COMMAND rm -rf ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/config
 
-                                       COMMAND rm -rf ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/site-packages
-                                       COMMAND mkdir ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/site-packages    # python needs it.
+                                       COMMAND rm -rf ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/site-packages
+                                       COMMAND mkdir ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/site-packages    # python needs it.
 
-                                       COMMAND rm -f ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION}/lib-dynload/_tkinter.so
-                                       COMMAND find ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION} -name "test" -prune -exec rm -rf {} "\;"
-                                       COMMAND find ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION} -name "*.py?" -exec rm -rf {} "\;"
-                                       COMMAND find ${TARGETDIR}/.blender/python/lib/python${PYTHON_VERSION} -name "*.so"-exec strip -s {} "\;"
+                                       COMMAND rm -f ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION}/lib-dynload/_tkinter.so
+                                       COMMAND find ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION} -name "test" -prune -exec rm -rf {} "\;"
+                                       COMMAND find ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION} -name "*.py?" -exec rm -rf {} "\;"
+                                       COMMAND find ${TARGETDIR}/${BLENDER_VERSION}/python/lib/python${PYTHON_VERSION} -name "*.so"-exec strip -s {} "\;"
                                )
                        ENDIF(WITH_PYTHON_INSTALL)
                ENDIF(WITH_PYTHON)