Author: raja
Date: 2005-04-21 05:58:41 -0400 (Thu, 21 Apr 2005)
New Revision: 43391
Added:
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/
trunk/mcs/class/Microsoft.VisualBasic/fixup/
trunk/mcs/class/Microsoft.VisualBasic/fixup/Makefile
trunk/mcs/class/Microsoft.VisualBasic/fixup/default/
trunk/mcs/class/Microsoft.VisualBasic/fixup/fixup.pl
trunk/mcs/class/Microsoft.VisualBasic/fixup/net_2_0/
Removed:
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/
trunk/mcs/class/Microsoft.VisualBasic/fixup.pl
Modified:
trunk/mcs/class/Microsoft.VisualBasic/ChangeLog
trunk/mcs/class/Microsoft.VisualBasic/Makefile
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.csproj
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.dll.sources
Log:
* Makefile (NO_SIGN_ASSEMBLY, NO_INSTALL): Set. The actual signing
and installation is handled by fixup/Makefile.
(test_against, test_dep): Point to the fixed up dll.
* fixup/Makefile: New makefile. Handles calling 'fixup.pl' on the
build assembly, and installing it.
Modified: trunk/mcs/class/Microsoft.VisualBasic/ChangeLog
===================================================================
--- trunk/mcs/class/Microsoft.VisualBasic/ChangeLog 2005-04-21 09:56:32 UTC
(rev 43390)
+++ trunk/mcs/class/Microsoft.VisualBasic/ChangeLog 2005-04-21 09:58:41 UTC
(rev 43391)
@@ -1,5 +1,10 @@
2005-04-21 Raja R Harinath <[EMAIL PROTECTED]>
+ * Makefile (NO_SIGN_ASSEMBLY, NO_INSTALL): Set. The actual signing
+ and installation is handled by fixup/Makefile.
+ (test_against, test_dep): Point to the fixed up dll.
+ * fixup/Makefile: New makefile. Handles calling 'fixup.pl' on the
+ build assembly, and installing it.
* fixup.pl: Allow input from stdin.
2005-04-21 Ankit Jain <[EMAIL PROTECTED]>
Modified: trunk/mcs/class/Microsoft.VisualBasic/Makefile
===================================================================
--- trunk/mcs/class/Microsoft.VisualBasic/Makefile 2005-04-21 09:56:32 UTC
(rev 43390)
+++ trunk/mcs/class/Microsoft.VisualBasic/Makefile 2005-04-21 09:58:41 UTC
(rev 43391)
@@ -1,8 +1,16 @@
thisdir = class/Microsoft.VisualBasic
-SUBDIRS =
+SUBDIRS = fixup
include ../../build/rules.make
+# Build current directory before subdirs
+all-recursive: all-local
+$(STD_TARGETS:%=%-recursive): %-recursive: %-local
+
+# The actual library will be built and signed in the 'fixup' directory
+NO_INSTALL = yes
+NO_SIGN_ASSEMBLY = yes
+
LIBRARY = Microsoft.VisualBasic.dll
LIB_MCS_FLAGS = /r:$(corlib) /r:System.dll /r:System.Windows.Forms.dll
@Microsoft.VisualBasic.dll.resources -codepage:65001
TEST_MCS_FLAGS = -codepage:65001 -nowarn:0618 -nowarn:219 -nowarn:169
@@ -15,6 +23,10 @@
EXTRA_DISTFILES = Microsoft.VisualBasic.dll.resources
$(TXT_RES:.resources=.txt) #$(RESX_RES:.resources=.resx)
CLEAN_FILES = $(TXT_RES) #$(RESX_RES)
+# Testcases are run against the fixed-up library
+test_against = fixup/$(PROFILE)/$(LIBRARY)
+test_dep = $(test_against)
+
include ../../build/library.make
$(the_lib): $(TXT_RES) #$(RESX_RES)
@@ -24,3 +36,6 @@
#$(RESX_RES): %.resources: %.resx
# $(RESGEN) `echo $< | $(PLATFORM_CHANGE_SEPARATOR_CMD)`
+
+$(test_dep): $(the_lib)
+ cd fixup && $(MAKE)
Copied:
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices
(from rev 43381,
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices)
Modified: trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.csproj
===================================================================
--- trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.csproj
2005-04-21 09:56:32 UTC (rev 43390)
+++ trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.csproj
2005-04-21 09:58:41 UTC (rev 43391)
@@ -324,141 +324,141 @@
BuildAction = "Content"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\BooleanType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\BooleanType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\ByteType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\ByteType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\ChangeLog"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\ChangeLog"
BuildAction = "None"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\CharArrayType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\CharArrayType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\CharType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\CharType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\DateType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\DateType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\DecimalType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\DecimalType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\DefaultArgumentValueAttribute.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\DefaultArgumentValueAttribute.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\DoubleType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\DoubleType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\ExceptionUtils.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\ExceptionUtils.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\FlowControl.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\FlowControl.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\IncompleteInitialization.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\IncompleteInitialization.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\IntegerType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\IntegerType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\LateBinding.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\LateBinding.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\LongType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\LongType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\ObjectType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\ObjectType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\OptionCompareAttribute.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\OptionCompareAttribute.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\OptionTextAttribute.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\OptionTextAttribute.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\ProjectData.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\ProjectData.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\ShortType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\ShortType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\SingleType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\SingleType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\StandardModuleAttribute.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\StandardModuleAttribute.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\StaticLocalInitFlag.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\StaticLocalInitFlag.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\StringType.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\StringType.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\TODOAttribute.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\TODOAttribute.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\Utils.cs"
+ RelPath = "Microsoft.VisualBasic.CompilerServices\Utils.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\VBBinder.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\VBBinder.cs"
SubType = "Code"
BuildAction = "Compile"
/>
<File
- RelPath =
"Microsoft.VisualBasic\Microsoft.VisualBasic.CompilerServices\VBErrors.cs"
+ RelPath =
"Microsoft.VisualBasic.CompilerServices\VBErrors.cs"
SubType = "Code"
BuildAction = "Compile"
/>
Modified:
trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.dll.sources
===================================================================
--- trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.dll.sources
2005-04-21 09:56:32 UTC (rev 43390)
+++ trunk/mcs/class/Microsoft.VisualBasic/Microsoft.VisualBasic.dll.sources
2005-04-21 09:58:41 UTC (rev 43391)
@@ -44,32 +44,32 @@
Microsoft.VisualBasic/OutPutVBFile.cs
Microsoft.VisualBasic/RandomVBFile.cs
Microsoft.VisualBasic/BinaryVBFile.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/BooleanType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/ByteType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/CharArrayType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/CharType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/DateType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/DecimalType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/DoubleType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/ExceptionUtils.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/FlowControl.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/HostServices.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/IVbHost.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/IncompleteInitialization.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/IntegerType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/LateBinding.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/LongType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/ObjectType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/OptionCompareAttribute.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/OptionTextAttribute.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/ProjectData.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/ShortType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/SingleType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/StandardModuleAttribute.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/StaticLocalInitFlag.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/StringType.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/TODOAttribute.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/Utils.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/VBBinder.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/VBErrors.cs
-Microsoft.VisualBasic/Microsoft.VisualBasic.CompilerServices/DefaultArgumentValueAttribute.cs
+Microsoft.VisualBasic.CompilerServices/BooleanType.cs
+Microsoft.VisualBasic.CompilerServices/ByteType.cs
+Microsoft.VisualBasic.CompilerServices/CharArrayType.cs
+Microsoft.VisualBasic.CompilerServices/CharType.cs
+Microsoft.VisualBasic.CompilerServices/DateType.cs
+Microsoft.VisualBasic.CompilerServices/DecimalType.cs
+Microsoft.VisualBasic.CompilerServices/DoubleType.cs
+Microsoft.VisualBasic.CompilerServices/ExceptionUtils.cs
+Microsoft.VisualBasic.CompilerServices/FlowControl.cs
+Microsoft.VisualBasic.CompilerServices/HostServices.cs
+Microsoft.VisualBasic.CompilerServices/IVbHost.cs
+Microsoft.VisualBasic.CompilerServices/IncompleteInitialization.cs
+Microsoft.VisualBasic.CompilerServices/IntegerType.cs
+Microsoft.VisualBasic.CompilerServices/LateBinding.cs
+Microsoft.VisualBasic.CompilerServices/LongType.cs
+Microsoft.VisualBasic.CompilerServices/ObjectType.cs
+Microsoft.VisualBasic.CompilerServices/OptionCompareAttribute.cs
+Microsoft.VisualBasic.CompilerServices/OptionTextAttribute.cs
+Microsoft.VisualBasic.CompilerServices/ProjectData.cs
+Microsoft.VisualBasic.CompilerServices/ShortType.cs
+Microsoft.VisualBasic.CompilerServices/SingleType.cs
+Microsoft.VisualBasic.CompilerServices/StandardModuleAttribute.cs
+Microsoft.VisualBasic.CompilerServices/StaticLocalInitFlag.cs
+Microsoft.VisualBasic.CompilerServices/StringType.cs
+Microsoft.VisualBasic.CompilerServices/TODOAttribute.cs
+Microsoft.VisualBasic.CompilerServices/Utils.cs
+Microsoft.VisualBasic.CompilerServices/VBBinder.cs
+Microsoft.VisualBasic.CompilerServices/VBErrors.cs
+Microsoft.VisualBasic.CompilerServices/DefaultArgumentValueAttribute.cs
Added: trunk/mcs/class/Microsoft.VisualBasic/fixup/Makefile
===================================================================
--- trunk/mcs/class/Microsoft.VisualBasic/fixup/Makefile 2005-04-21
09:56:32 UTC (rev 43390)
+++ trunk/mcs/class/Microsoft.VisualBasic/fixup/Makefile 2005-04-21
09:58:41 UTC (rev 43391)
@@ -0,0 +1,100 @@
+thisdir = class/Microsoft.VisualBasic/fixup
+
+include ../../../build/rules.make
+
+with_mono_path =
MONO_PATH="$(topdir)/class/lib/$(PROFILE)$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH"
+ILDISASM = monodis
+PERL = perl
+
+# ----------------------------------------------
+# Minor hack. Copied from build/library.make
+
+ifeq ($(PLATFORM), win32)
+GACDIR = `cygpath -w $(mono_libdir)`
+GACROOT = `cygpath -w $(DESTDIR)$(mono_libdir)`
+test_flags += -d:WINDOWS
+else
+GACDIR = $(mono_libdir)
+GACROOT = $(DESTDIR)$(mono_libdir)
+endif
+
+ifdef NO_INSTALL
+GACUTIL = :
+else
+gacutil = $(topdir)/class/lib/net_1_1_bootstrap/gacutil.exe
+GACUTIL =
MONO_PATH="$(topdir)/class/lib/net_1_1_bootstrap$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH"
$(RUNTIME) $(gacutil)
+endif
+
+ifdef NO_SIGN_ASSEMBLY
+SN = :
+else
+sn = $(topdir)/class/lib/net_1_1_bootstrap/sn.exe
+SN =
MONO_PATH="$(topdir)/class/lib/net_1_1_bootstrap$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH"
$(RUNTIME) $(sn)
+SNFLAGS = -q -R
+endif
+
+# ----------------------------------------------
+
+ilasm = $(topdir)/class/lib/net_1_1_bootstrap/ilasm.exe
+ILASM =
MONO_PATH="$(topdir)/class/lib/net_1_1_bootstrap$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH"
$(RUNTIME) $(ilasm)
+
+the_lib = $(PROFILE)/Microsoft.VisualBasic.dll
+the_il = $(the_lib:.dll=.il)
+
+all-local: $(the_lib)
+
+$(the_lib): $(the_il) Microsoft.VisualBasic.VBUtils.resources
+ $(ILASM) /out:$@ $<
+ $(SN) $(SNFLAGS) $@ $(topdir)/class/mono.snk
+
+$(the_il): $(topdir)/class/lib/$(PROFILE)/Microsoft.VisualBasic.dll
+ $(with_mono_path) $(ILDISASM) $< | $(PERL) ./fixup.pl > $@
+
+Microsoft.VisualBasic.VBUtils.resources:
../Microsoft.VisualBasic/VBUtils.resources
+ cp $< $@
+
+test-local run-test-local run-test-ondotnet-local:
+ @:
+
+# ----------------------------------------------
+# Minor hack. Copied from build/library.make
+
+ifdef NO_INSTALL
+install-local uninstall-local:
+ @:
+
+else
+
+ifdef LIBRARY_INSTALL_DIR
+install-local:
+ $(MKINSTALLDIRS) $(DESTDIR)$(LIBRARY_INSTALL_DIR)
+ $(INSTALL_LIB) $(the_lib)
$(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME)
+ test ! -f $(the_lib).mdb || $(INSTALL_LIB) $(the_lib).mdb
$(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME).mdb
+
+uninstall-local:
+ -rm -f $(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME)
$(DESTDIR)$(LIBRARY_INSTALL_DIR)/$(LIBRARY_NAME).mdb
+
+else
+
+# If RUNTIME_HAS_CONSISTENT_GACDIR is set, it implies that the internal GACDIR
+# of the runtime is the same as the GACDIR we want. So, we don't need to pass
it
+# to gacutil. Note that the GACDIR we want may not be the same as the value of
+# GACDIR set above, since the user could have overridden the value of
$(prefix).
+#
+# This makes a difference only when we're building from the mono/ tree, since
we
+# have to ensure that the internal GACDIR of the in-tree runtime matches where
we
+# install the DLLs.
+
+ifndef RUNTIME_HAS_CONSISTENT_GACDIR
+gacdir_flag = /gacdir $(GACDIR)
+endif
+
+install-local: $(gacutil)
+ $(GACUTIL) /i $(the_lib) /f $(gacdir_flag) /root $(GACROOT) /package
$(FRAMEWORK_VERSION)
+
+uninstall-local: $(gacutil)
+ -$(GACUTIL) /u Microsoft.VisualBasic $(gacdir_flag) /root $(GACROOT)
/package $(FRAMEWORK_VERSION)
+
+endif
+endif
+# ----------------------------------------------
Copied: trunk/mcs/class/Microsoft.VisualBasic/fixup/fixup.pl (from rev 43384,
trunk/mcs/class/Microsoft.VisualBasic/fixup.pl)
Deleted: trunk/mcs/class/Microsoft.VisualBasic/fixup.pl
===================================================================
--- trunk/mcs/class/Microsoft.VisualBasic/fixup.pl 2005-04-21 09:56:32 UTC
(rev 43390)
+++ trunk/mcs/class/Microsoft.VisualBasic/fixup.pl 2005-04-21 09:58:41 UTC
(rev 43391)
@@ -1,64 +0,0 @@
-#!/usr/bin/perl -w
-#
-# fixup.pl
-#
-# Authors:
-# Ankit Jain ([EMAIL PROTECTED])
-#
-# Copyright (C) 2005 Novell, Inc (http://www.novell.com)
-#
-# Permission is hereby granted, free of charge, to any person obtaining
-# a copy of this software and associated documentation files (the
-# "Software"), to deal in the Software without restriction, including
-# without limitation the rights to use, copy, modify, merge, publish,
-# distribute, sublicense, and/or sell copies of the Software, and to
-# permit persons to whom the Software is furnished to do so, subject to
-# the following conditions:
-#
-# The above copyright notice and this permission notice shall be
-# included in all copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-while (<>) {
- if (/\.custom instance
void\s+(?:class\s+)?Microsoft\.VisualBasic\.CompilerServices\.__DefaultArgumentValueAttribute::\.ctor\s*\(([^)]*)\)\s*=\s*\(([^)]*)\)/)
{
-
- my @str = split (/ /, $2);
- if ($1 =~ /string/) {
- # FIXME: Assumes length < 0x80.
- $size = hex $str [2];
-
- if ($size == 0) {
- print ("= \"\"\n");
- }elsif ($size == 255) {
- print ("= nullref\n");
- }else{
- # FIXME: Should be a UTF-8 to UCS-2 translator.
However, we only use ASCII.
- print "= bytearray ( ";
- for ($i = 3; $i < @str - 2; $i ++) {
- print $str [$i] . " 00 ";
- }
- print " )\n";
- }
- }elsif ($1 =~ /bool/) {
- print "= bool (" . ($str [2] == '00' ? "false" :
"true") . ")\n";
- }else {
- print "= $1 (0x";
-
- for ($i = @str - 2 - 1; $i >= 2;$i --) {
- print $str [$i] ;
- }
-
- print ")\n";
- }
- }else{
- print;
- }
-}
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches