Ignore:
Timestamp:
03/20/12 15:16:45 (8 years ago)
Author:
hinerm
Message:

Updated CMakeLists template for Windows

CMakeLists.txt generated using Jar2Lib will now
include a "J2L_WIN_BUILD_DEBUG" boolean option.

If set to "ON" (default) then Windows builds will
build the Debug version of the application, or Release
if this is set to "OFF".

Also removed instances of double "/".

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/projects/jar2lib/src/main/resources/CMakeLists.vm

    r7776 r7925  
    4848endif(UNIX) 
    4949 
     50option(J2L_WIN_BUILD_DEBUG "Build Debug version? If false, builds Release. Windows only." ON) 
     51 
     52if(${J2L_WIN_BUILD_DEBUG} STREQUAL "ON") 
     53  if(NOT DEFINED J2L_BUILD_VALUE) 
     54    set(J2L_BUILD_VALUE Debug) 
     55  endif(NOT DEFINED J2L_BUILD_VALUE) 
     56elseif(${J2L_WIN_BUILD_DEBUG} STREQUAL "OFF") 
     57  if(NOT DEFINED J2L_BUILD_VALUE) 
     58    set(J2L_BUILD_VALUE Release) 
     59  endif(NOT DEFINED J2L_BUILD_VALUE) 
     60endif(${J2L_WIN_BUILD_DEBUG} STREQUAL "ON") 
     61 
    5062# post-build copies to dist dir 
    5163if(NOT DEFINED Jar2Lib_JACE_DIR) 
     
    5466 
    5567if(NOT DEFINED Jar2Lib_PROXY_DIR) 
    56   set(Jar2Lib_PROXY_DIR /proxies) 
     68  set(Jar2Lib_PROXY_DIR proxies) 
    5769endif(NOT DEFINED Jar2Lib_PROXY_DIR) 
    5870 
     
    112124if(WIN32) 
    113125   set(J2L_LIB_PREFIX "") 
    114    set(J2L_BUILD_TYPE /Release) 
    115  
    116 # Building in Debug mode is not currently supported in this script 
    117 #  set(J2L_BUILD_TYPE /Debug) 
     126 
     127   if(NOT DEFINED J2L_BUILD_TYPE) 
     128     set(J2L_BUILD_TYPE ${J2L_BUILD_VALUE}) 
     129   endif(NOT DEFINED J2L_BUILD_TYPE) 
    118130 
    119131  if(NOT DEFINED J2L_SUFFIX) 
    120  
    121132    set(J2L_SUFFIX .dll) 
    122  
    123133  endif(NOT DEFINED J2L_SUFFIX) 
    124134 
    125  if(NOT DEFINED J2L_EXE_SUFFIX) 
    126    set(J2L_EXE_SUFFIX .exe) 
    127  endif(NOT DEFINED J2L_EXE_SUFFIX) 
     135  if(NOT DEFINED J2L_EXE_SUFFIX) 
     136    set(J2L_EXE_SUFFIX .exe) 
     137  endif(NOT DEFINED J2L_EXE_SUFFIX) 
    128138 
    129139endif(WIN32) 
     
    131141if(WIN64) 
    132142  set(J2L_LIB_PREFIX "") 
    133   set(J2L_BUILD_TYPE /Release) 
    134  
    135 #  Builing with Debug mode on Windows is not currently supported in this script. 
    136 #  set(J2L_BUILD_TYPE /Debug) 
     143 
     144  if(NOT DEFINED J2L_BUILD_TYPE) 
     145    set(J2L_BUILD_TYPE ${J2L_BUILD_VALUE}) 
     146  endif(NOT DEFINED J2L_BUILD_TYPE) 
    137147 
    138148  if(NOT DEFINED J2L_SUFFIX) 
Note: See TracChangeset for help on using the changeset viewer.