[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Generating VC6 project files for swig bindings

From: Russell Yanofsky <rey4_at_columbia.edu>
Date: 2003-06-18 07:53:35 CEST

> Now I'd like to see a few things changed, if you don't mind. :-)

Ok. I was able to handle these things:

> * Move the unique() function to gen_base.py. There are quite a few
> places where we can use it.
> * Prefix the project names with "swig_"; e.g., "swig_python_core"
> instead of just "python_core". This will make the project lists
> more readable.
> * Add new pseudo projects (in build.conf): __SWIG_PYTHON__ and
> __SWIG_JAVA__, to build all the relevant bindings in one fell
> swoop. * Put the target description back in, so that we get
> version info in the generated DLLs.

But not these:

> * Change the SWIG custom build commands to generate the C files in
> the build tree (Release or Debug), _not_ the source tree. This
> means tweaking the source file definitions for the C files, too.
> * Fix the link warnings about not finding aprutil_src.pdb or
> xml_src.pdb -- I guess that means adding library dependencies to
> the link lines for the DLLs.

I couldn't figure out a way to tell Visual C++ to compile different C source
files depending on the configuration (release or debug). I tried putting
conditionals ('!IF "$(CFG)" == "whatever" / !ENDIF) around the SOURCE=...
statements in the project files, but that made only them unloadable. So swig
still outputs the C files in the source tree since it's a neutral location.

I couldn't do anything about the link warnings since I don't get them and I
don't know what causes them.

Patch is attached.

- Russ

Log Message:

* build.conf: added description strings for swig libraries and two new
  utility targets, __SWIG_PYTHON__ and __SWIG_JAVA__.

* build/generator/gen_base.py (GeneratorBase.__init__): added new parser
  option "language" which is needed for the new __SWIG_*_ targets.

  (TargetSWIG.add_dependencies): changed to set the description attribute
  on each newly created SWIGLibrary.

  Declared a new class called TargetSwigUtility which inherits from
  TargetUtility for swig utility targets.

* build/generator/gen_win.py: (unique) transplanted this function from
  gen_msvc_dsp.py

  (WinGeneratorBase.get_unique_win_depends): now adds SWIGLibraries as
  dependencies of TargetSwigUtility targets.

* build/generator/gen_msvc_dsp.py: (unique) moved this function to a
  gen_win.py

  (Generator.write_project): no longer assigns None to the SWIGLibraries'
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W9C7V1S<"YP>0DH<F5V:7-I;VX@-C(W-"D**RLK(&)U:6QD+V=E
M;F5R871O<B]G96Y?;7-V8U]D<W N<'D)*'=O<FMI;F<@8V]P>2D*0$ @+30W
M+#<@*S0W+#8@0$ *(" @(" @('1A<F=T>7!E(#T@(E=I;C,R("AX.#8I($1Y
M;F%M:6,M3&EN:R!,:6)R87)Y(@H@(" @(" @=&%R9W9A;" ]("(P># Q,#(B
M"B @(" @("!T87)G970N;W5T<'5T7VYA;64@/2!O<RYP871H+F)A<V5N86UE
M*'1A<F=E="YF;F%M92D*+2 @(" @('1A<F=E="YD97-C(#T@3F]N90H@(" @
M(" @=&%R9V5T+FES7V%P86-H95]M;V0@/2 P"B @(" @96QS93H*(" @(" @
M(')A:7-E(&=E;E]B87-E+D=E;D5R<F]R*")#86YN;W0@8W)E871E('!R;VIE
M8W0@9F]R("5S(B E('1A<F=E="YN86UE*0I 0" M,3(T+#@@*S$R,RPX($!
M"B @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @
M(" @(" @(" @("!.;VYE+"!.;VYE+"!S96QF+F-F9RP*(" @(" @(" @(" @
M(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @(" @($YO
M;F4I"B *+2 @("!I;G-T86QL7W1A<F=E=',@/2!U;FEQ=64H<V5L9BYG<F%P
M:"YG971?86QL7W-O=7)C97,H9V5N7V)A<V4N1%1?24Y35$%,3"D*+2 @(" @
M(" @(" @(" @(" @(" @(" @(" @(" @*R!S96QF+G1A<F=E=',N=F%L=65S
M*"DI"BL@(" @:6YS=&%L;%]T87)G971S(#T@9V5N7W=I;BYU;FEQ=64H<V5L
M9BYT87)G971S+G9A;'5E<R@I"BL@(" @(" @(" @(" @(" @(" @("L@<V5L
M9BYG<F%P:"YG971?86QL7W-O=7)C97,H9V5N7V)A<V4N1%1?24Y35$%,3"DI
M"B *(" @(" C('-O<G0@=&AE<V4@9F]R(&]U='!U="!S=&%B:6QI='DL('1O
M('=A=&-H(&]U="!F;W(@<F5G<F5S<VEO;G,N"B @(" @:6YS=&%L;%]T87)G
M971S+G-O<G0H*0I 0" M,30P+#8@*S$S.2PX($! "B @(" @("!P;W,@/2!S
M=')I;F<N9FEN9"AN86UE+" G+71E<W0G*0H@(" @(" @:68@<&]S(#X](# Z
M"B @(" @(" @(&1S<%]N86UE(#T@)W1E<W1?)R K('-T<FEN9RYR97!L86-E
M*&YA;65;.G!O<UTL("<M)RP@)U\G*0HK(" @(" @96QI9B!I<VEN<W1A;F-E
M*'1A<F=E="P@9V5N7V)A<V4N4U=)1TQI8G)A<GDI.@HK(" @(" @("!D<W!?
M;F%M92 ]("=S=VEG7R<@*R!S=')I;F<N<F5P;&%C92AN86UE+" G+2<L("=?
M)RD*(" @(" @(&5L<V4Z"B @(" @(" @(&1S<%]N86UE(#T@<W1R:6YG+G)E
M<&QA8V4H;F%M92P@)RTG+" G7R<I"B @(" @("!T87)G970N9'-P7VYA;64@
M/2!D<W!?;F%M90I 0" M,C,Q+#D@*S(S,BPS($! "B!C;&%S<R!?:71E;3H*
M(" @9&5F(%]?:6YI=%]?*'-E;&8L("HJ:W<I.@H@(" @('9A<G,H<V5L9BDN
M=7!D871E*&MW*0HM"BUD968@=6YI<75E*'-E<2DZ"BT@(&0@/2![?0HM("!F
M;W(@:2!I;B!S97$Z"BT@(" @9%MI72 ]($YO;F4*+2 @<F5T=7)N(&0N:V5Y
$<R@I"@``
`
end

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Jun 18 07:54:52 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.