[cmake-developers] [CMake 0013042]: UseSWIG.cmake: subdirectory for generated files is not created

Mantis Bug Tracker mantis at public.kitware.com
Wed Mar 14 12:09:46 EDT 2012


The following issue has been SUBMITTED. 
====================================================================== 
http://public.kitware.com/Bug/view.php?id=13042 
====================================================================== 
Reported By:                Bjoern Thiel
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   13042
Category:                   Modules
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2012-03-14 12:09 EDT
Last Modified:              2012-03-14 12:09 EDT
====================================================================== 
Summary:                    UseSWIG.cmake: subdirectory for generated files is
not created
Description: 
In case one .i file is sitting in a subdirectory of the current directory, the
corresponding subdirectory for the generated .cxx file is not created. 

So SWIG produces no output for the corresponding input.

Steps to Reproduce: 
see above

Additional Information: 
quick fix:
change
  IF(swig_source_file_relative_path)
    SET(swig_generated_file_fullname
      "${swig_generated_file_fullname}/${swig_source_file_relative_path}")
  ENDIF(swig_source_file_relative_path)
to
  IF(swig_source_file_relative_path)
    SET(swig_generated_file_fullname
      "${swig_generated_file_fullname}/${swig_source_file_relative_path}")
    FILE(MAKE_DIRECTORY "${swig_generated_file_fullname}")
  ENDIF(swig_source_file_relative_path)

====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2012-03-14 12:09 Bjoern Thiel   New Issue                                    
======================================================================




More information about the cmake-developers mailing list