Hey all,

I got tired of waiting for swig to re-generate all of the files each
time I had to go fix a few bugs in the build process. So, here's the
fix to not call swig when swig has already done its job. Note however
that you need to be careful about this if you are not sure whether or
not the *_wrap.cc files need to be regenerated or not. I'm fairly
certain that all of the *_wrap.cc files are generated based off of *
being from the list of modules given in Modules.py. Anyway, here's the
fix (pay close attention to the "if not").

---------
for module in MODULES:
        module_name = module[0]
        SWIG_source_file =
os.path.join(os.getcwd(),SWIG_FILES_PATH_MODULAR,"%s.i"%module_name)
        SHARED_Library_pathname = os.path.join(BUILD_DIR,'%s'%module_name)
        if not 
(os.path.isfile(os.path.join(os.getcwd(),SWIG_FILES_PATH_MODULAR,"%s_wrap.cc"%module_name))):
                env.SharedLibrary(SHARED_Library_pathname,
[SWIG_source_file],SHLIBPREFIX = '_', SHLIBSUFFIX =
sysconfig.get_config_vars()['SO'])
---------
(in particular, this should go at the bottom of SConstruct, look for
the line "Build shared libraries".)

- Bryan
http://heybryan.org/
1 512 203 0507

_______________________________________________
Pythonocc-users mailing list
Pythonocc-users@gna.org
https://mail.gna.org/listinfo/pythonocc-users

Reply via email to