You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Daniel Rall <dl...@finemaltcoding.com> on 2002/12/10 18:17:10 UTC
Re: svn commit: rev 4077 - trunk
dlr@tigris.org writes:
> # FIXME: Replace inline Perl invocation with something cleaner.
> swig-java-ext: swig-assert-available mkdir-init
> - cd $(SWIG_SRC_DIR); \
> - for source in *.i; do \
> - target="`echo -n $$source | perl -pe 's/\.i$$/.c/'`"; \
> - $(SWIG) -c -java -noproxy -module 'svn_' \
> + cd $(SWIG_SRC_DIR)/java/org/tigris/subversion/swig; \
> + for source in $(SWIG_SRC_DIR)/*.i; do \
> + target="`echo -n $$source | perl -pe 's!^.*/(.+)\.i$$!$$1.c!'`"; \
> + $(SWIG) -c -java -noproxy -module 'Subversion' \
> + -package 'org.tigris.subversion.swig' \
> -I$(SWIG_SRC_DIR) \
> -I$(abs_srcdir)/subversion/include $(SVN_APR_INCLUDES) \
> -o java/build/$$target $$source; \
> done
Within Subversion's build process, what is the Right Way to handle the
inline Perl invocation at the beginning of the shell "for" loop? m4
and sed (two tools I'm less familiar with)? Suggestions appreciated.
--
Daniel Rall <dl...@finemaltcoding.com>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 4077 - trunk
Posted by Daniel Rall <dl...@finemaltcoding.com>.
Daniel Rall <dl...@finemaltcoding.com> writes:
> I used a slight variation, which includes start and end anchors, and
> drops the -n (be quiet) option and p (print) command which seemed to
> cancel each other out.
Er, rather, p overrides -n, but since to print seems to be the default
behavior anyhow, dropping both of them made sense in my environment.
Slap me if it isn't portable.
p.s. Are windows folks building the swig bindings using this Makefile?
--
Daniel Rall <dl...@finemaltcoding.com>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 4077 - trunk
Posted by Daniel Rall <dl...@finemaltcoding.com>.
Matt Kraai <kr...@alumni.cmu.edu> writes:
> On Tue, Dec 10, 2002 at 10:17:10AM -0800, Daniel Rall wrote:
> > dlr@tigris.org writes:
> >
> > > # FIXME: Replace inline Perl invocation with something cleaner.
> > > swig-java-ext: swig-assert-available mkdir-init
> > > - cd $(SWIG_SRC_DIR); \
> > > - for source in *.i; do \
> > > - target="`echo -n $$source | perl -pe 's/\.i$$/.c/'`"; \
> > > - $(SWIG) -c -java -noproxy -module 'svn_' \
> > > + cd $(SWIG_SRC_DIR)/java/org/tigris/subversion/swig; \
> > > + for source in $(SWIG_SRC_DIR)/*.i; do \
> > > + target="`echo -n $$source | perl -pe 's!^.*/(.+)\.i$$!$$1.c!'`"; \
> > > + $(SWIG) -c -java -noproxy -module 'Subversion' \
> > > + -package 'org.tigris.subversion.swig' \
> > > -I$(SWIG_SRC_DIR) \
> > > -I$(abs_srcdir)/subversion/include $(SVN_APR_INCLUDES) \
> > > -o java/build/$$target $$source; \
> > > done
> >
> > Within Subversion's build process, what is the Right Way to handle the
> > inline Perl invocation at the beginning of the shell "for" loop? m4
> > and sed (two tools I'm less familiar with)? Suggestions appreciated.
>
> Does
>
> target="`echo $$source | sed -n 's,.*/\(.*\).i,\1.c,p'`"; \
>
> work?
It does. I used a slight variation, which includes start and end
anchors, and drops the -n (be quiet) option and p (print) command
which seemed to cancel each other out. Committed as r4083.
target="`echo -n $$source | sed 's!^.*/\(.*\)\.i$$!\1.c!'`"; \
Thanks!
--
Daniel Rall <dl...@finemaltcoding.com>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: svn commit: rev 4077 - trunk
Posted by Matt Kraai <kr...@alumni.cmu.edu>.
On Tue, Dec 10, 2002 at 10:17:10AM -0800, Daniel Rall wrote:
> dlr@tigris.org writes:
>
> > # FIXME: Replace inline Perl invocation with something cleaner.
> > swig-java-ext: swig-assert-available mkdir-init
> > - cd $(SWIG_SRC_DIR); \
> > - for source in *.i; do \
> > - target="`echo -n $$source | perl -pe 's/\.i$$/.c/'`"; \
> > - $(SWIG) -c -java -noproxy -module 'svn_' \
> > + cd $(SWIG_SRC_DIR)/java/org/tigris/subversion/swig; \
> > + for source in $(SWIG_SRC_DIR)/*.i; do \
> > + target="`echo -n $$source | perl -pe 's!^.*/(.+)\.i$$!$$1.c!'`"; \
> > + $(SWIG) -c -java -noproxy -module 'Subversion' \
> > + -package 'org.tigris.subversion.swig' \
> > -I$(SWIG_SRC_DIR) \
> > -I$(abs_srcdir)/subversion/include $(SVN_APR_INCLUDES) \
> > -o java/build/$$target $$source; \
> > done
>
> Within Subversion's build process, what is the Right Way to handle the
> inline Perl invocation at the beginning of the shell "for" loop? m4
> and sed (two tools I'm less familiar with)? Suggestions appreciated.
Does
target="`echo $$source | sed -n 's,.*/\(.*\).i,\1.c,p'`"; \
work?
Matt
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org