[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Dotgnu-libs-commits] CVS: libxmlsharp/tools newclass.sh,NONE,1.1 pinvok
From: |
Gopal.V <address@hidden> |
Subject: |
[Dotgnu-libs-commits] CVS: libxmlsharp/tools newclass.sh,NONE,1.1 pinvoke.sh,NONE,1.1 template.cs.in,NONE,1.1 |
Date: |
Thu, 04 Jul 2002 19:47:20 -0400 |
Update of /cvsroot/dotgnu-libs/libxmlsharp/tools
In directory subversions:/tmp/cvs-serv12841/tools
Added Files:
newclass.sh pinvoke.sh template.cs.in
Log Message:
First Post
--- NEW FILE ---
cat template.cs.in | sed "s/%NAME%/$1/g" > $1.cs
--- NEW FILE ---
###############TRICK SCRIPT############
#
# To do the work of cscc , and work with
# pinvoke from a specific lib $PINVOKE_SO
# for funcs in $PINVOKE_FUNCS
#######################################
PINVOKE_FILE="Native.cs"
PINVOKE_PREFIX="_xml"
PINVOKE_FUNCS=`cat $PINVOKE_FILE | grep "$PINVOKE_PREFIX" | sed
"s/.*\($PINVOKE_PREFIX[^(]*\).*$/\1/"`
PINVOKE_SO="libxml_wrapper"
TMP0_FILE="$1.iltmp0"
TMP1_FILE="$1.iltmp1"
SWAP_VAR=""
OUT_FILE="$1"
[ -f $1 ] || echo "Not found $1"
[ -f $1 ] || exit 0;
grep "pinvokeimpl" $1 >/dev/null && echo "already processed ?";
grep "pinvokeimpl" $1 >/dev/null && exit 0;
cp $1 $1~
cat $1 > $TMP0_FILE
for each in $PINVOKE_FUNCS;
do
cat $TMP0_FILE | sed "s/\(\.method.*hidebysig\)\(.*\)'$each'(/\1
pinvokeimpl(\"$PINVOKE_SO\")\2'$each'(/g" > $TMP1_FILE;
if [ `python -c "print 1" >> /dev/null 2>&1 && echo 1` ] ; then
DOTS=`python -c "i=len(\"$each\");print \".\"*(50-i),"`
fi
echo "processing " $each $DOTS
SWAP_VAR=$TMP1_FILE;
TMP1_FILE=$TMP0_FILE;
TMP0_FILE=$SWAP_VAR;
done
cat $TMP0_FILE > $OUT_FILE
rm -f $TMP1_FILE $TMP0_FILE
--- NEW FILE ---
/*
* %NAME%.cs - %NAME% class
*
* Copyright (C) 2002 Gopal.V
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
using System;
namespace dotgnu.xml
{
public class %NAME%
{
}
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Dotgnu-libs-commits] CVS: libxmlsharp/tools newclass.sh,NONE,1.1 pinvoke.sh,NONE,1.1 template.cs.in,NONE,1.1,
Gopal.V <address@hidden> <=
- Prev by Date:
[Dotgnu-libs-commits] CVS: libxmlsharp/samples Makefile,NONE,1.1 builder.cs,NONE,1.1 ns.cs,NONE,1.1 ns.xml,NONE,1.1 struct.cs,NONE,1.1 struct.xml,NONE,1.1 tree.cs,NONE,1.1 tree.xml,NONE,1.1
- Next by Date:
[Dotgnu-libs-commits] CVS: libxmlsharp/wrapper Makefile,NONE,1.1 libxml_wrapper.c,NONE,1.1
- Previous by thread:
[Dotgnu-libs-commits] CVS: libxmlsharp/samples Makefile,NONE,1.1 builder.cs,NONE,1.1 ns.cs,NONE,1.1 ns.xml,NONE,1.1 struct.cs,NONE,1.1 struct.xml,NONE,1.1 tree.cs,NONE,1.1 tree.xml,NONE,1.1
- Next by thread:
[Dotgnu-libs-commits] CVS: libxmlsharp/wrapper Makefile,NONE,1.1 libxml_wrapper.c,NONE,1.1
- Index(es):