[sword-devel] Building Python binding to Sword on Windows returns exit code 1
R Johnson
ps16thypresenceisfullnessofjoy at gmail.com
Sat May 3 09:28:46 MST 2014
I asked a question on this list several months ago about how to build a
Python binding to Sword on Windows, and am finally getting around to
trying to do it. One of the BPBible developers said that he "used a
modified project file based on the Visual Studio project for C# in the
bindings/swig/vstudio directory to build with." Since this seems to be
the most official way to do it, I am trying it now.
I'm not very familiar with C++ or Visual Studio projects, so I'm
struggling somewhat to figure out how to do this. I made a copy of the
file "libsword_csharpsword.vcproj" in the above-mentioned directory, and
named it "libsword_pythonsword.vcproj". Then I made several changes to
it to try to make it build a Python binding instead of a C# one.
When I try to build the project, I get the following output (the error
message doesn't seem very descriptive to me):
1>------ Rebuild All started: Project: libsword_pythonsword,
Configuration: Release Win32 ------
1>..\..\..\include\swbuf.h(362): error : Syntax error in input(3).
1>C:\Program
Files\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppCommon.targets(103,5):
error MSB3073: The command "swig -python -c++ -nodefaultctor -DNDEBUG
-DWIN32 -D_LIB -DREGEX_MALLOC -DSWUSINGDLL -module Sword -o Sword.cxx
-I.. -I../../../include ../sword.i
1>C:\Program
Files\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppCommon.targets(103,5):
error MSB3073: :VCEnd" exited with code 1.
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
I have attached the project file that I have been trying to use. If you
compare it to the C# project using a diff tool, you can see the changes
I have made. Are there some that I still need to make but am missing?
Also, if anyone else has made Python bindings to Sword on Windows this
way, I think it would be very helpful to see the VS project file that
they used.
Thank you.
-- Timothy
P.S. I am using Visual Studio 2010 Express Edition to try to make Python
3.3 bindings to Sword 1.7.2 using SWIG 3.0.0 on a Windows 8.1 PC. In
order to use the project file in VS2010, it must be converted from the
old format to the VS2010 format.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: libsword_pythonsword.vcproj
Type: text/xml
Size: 19683 bytes
Desc: not available
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140503/80136725/attachment-0001.xml>
More information about the sword-devel
mailing list