I'm getting close on this, but there are still a few problem areas.

   1. When creating the executables after creating the PDFBox DLL, I get
   this warning for each one:      [exec] Note IKVMC0001: found main method in
   class "org.apache.pdfbox.PDFReader"
        [exec] Warning IKVMC0109: skipping class:
   "org.apache.pdfbox.PDFReader"
        [exec]     (class is already available in referenced assembly
   "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
   PublicKeyToken=null")
   1. That doesn't actually hurt anything, but it looks ugly and will scare
      people into thinking the build isn't working.
      2. The IKVM command line does not provide for suppressing warnings:
      http://www.ikvm.net/userguide/ikvmc.html
      3. There is an IKVM task for Ant which does provide a means of
      filtering out warnings using regular expressions.
      http://ant-ikvmc.sourceforge.net/  It requires that we include another
      JAR in our externals.
      2. BC Mail is missing a lot due to the dependencies on:
      1. javax.mail.  There's a fair amount of javax stuff that is not
      implemented in IKVM 0.38:
      
http://weblog.ikvm.net/PermaLink.aspx?guid=cf993fab-fb1b-4f05-9948-fcc9fc121a17
      2. org.bouncycastle.mail.smime.util.FileBackedMimeBodyPart
      3. org.bouncycastle.mail.smime.util.SharedFileInputStream
   3. The PDFBox DLL itself is omitting the
   org.apache.pdfbox.ant.PDFToTextTask because it is missing the class
   org.apache.ant.Task.  If I try to compile ant.jar to a DLL, I just run into
   another host of missing dependencies.
   4. We're also missing org.ibm.icu.text.Bidi and .Normalizer.

Would appreciate any suggestions.

Daniel Wilson

On Thu, Apr 30, 2009 at 9:20 AM, Daniel Wilson <
williamstonconsult...@gmail.com> wrote:

> >>Thanks to M$ for speaking error messages. NOT.
>
> Yeah, they're a mess ... but they've gotten a bit better with .NET.
>
> I mean making the ant script, in the build.NET target, copy in those
> DLL's.  The only people who would be running into that copy would be those
> who are building for .NET ... and they would already have the IKVM binaries
> in a folder that the ant script knows how to find.
>
> Like this:
>     <target name="build.NET"  ... etc.
>        <copy file="${ikvm.dir}/bin/IKVM.OpenJDK.ClassLibrary.dll"
> todir="bin" />
>        <copy file="${ikvm.dir}/bin/IKVM.runtime.dll" todir="bin" />
>
> We don't distribute a .NET build anyway do we?  If we did, we would have to
> distribute those DLL's.  That's just .NET for you.
>
> Daniel
>
>
> On Thu, Apr 30, 2009 at 9:10 AM, Jeremias Maerki 
> <d...@jeremias-maerki.ch>wrote:
>
>> On 30.04.2009 15:01:38 Daniel Wilson wrote:
>> > Unfortunately, your attachment didn't make it.
>>
>> Sorry. Should have zipped it.
>>
>> > As you had done on FontBox, I'm replacing the reference to
>> > IKVM.Gnu.Classpath with IKVM.OpenJDK.ClassLibrary.
>> >
>> > For the moment I'm also commenting out the instructions to build the JAI
>> > Codec and JAI Core.
>>
>> That's just what I did. :-)
>>
>> > I'm getting the warnings you posted, but if I copy
>> > IKVM.OpenJDB.ClassLibary.dll and IKVM.Runtime.dll into the output folder
>> > (pdfbox/trunk/bin) the executables do not crash on me.
>>
>> Ahhh! Thanks to M$ for speaking error messages. NOT. That's why I prefer
>> Java.
>>
>> > Is including a COPY directive in the ant script going to be a problem?
>>
>> You mean automatically copying over the necessary DLLs? I don't think so.
>> We'd have to take a closer look if we wanted to (re)distribute the DLLs.
>>
>> > Daniel
>> >
>> > On Thu, Apr 30, 2009 at 3:38 AM, Jeremias Maerki <d...@jeremias-maerki.ch
>> >wrote:
>> >
>> > > On 30.04.2009 09:28:02 Andreas Lehmkühler wrote:
>> > > > > Has anyone tried the IKVM build lately?
>> > > > >
>> > > > > Do we want to keep depending on 0.36 or should we move to 0.38?
>>  If the
>> > > > > latter, we need to update our build.xml significantly.
>> > > > I'm not familiar with that feature but Jeremias made some
>> adjustments
>> > > > to the build.xml of fontbox concerning the use of ikvm. Perhaps it
>> will
>> > > be
>> > > > easy to use these changes for pdfbox too.
>> > >
>> > > The latest IKVM uses OpenJDK so I adjusted for this, especially since
>> > > AWT is also better represented in IKVM now. So it makes sense to
>> update,
>> > > especially for PDFBox. However, I've just tried to do the same as with
>> > > FontBox but the whole thing doesn't work. Warnings/errors during
>> compile
>> > > and the binaries crash when started.
>> > >
>> > > build.NET:
>> > >     [echo] Building BC Prov
>> > >     [echo] Building BC Mail
>> > >     [exec] Warning IKVMC0100: class "javax.mail.BodyPart" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.MessagingException"
>> not
>> > > found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.internet.MimeBodyPart"
>> not
>> > > found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Part" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.internet.MimePart" not
>> > > found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.internet.MimeMessage"
>> not
>> > > found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Session" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Header" not found
>> > >     [exec] Warning IKVMC0100: class
>> "javax.mail.internet.MimeMultipart" not
>> > > found
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.bouncycastle.mail.smime.util.FileBackedMimeBodyPart"
>> > >     [exec]     (missing class "javax.mail.internet.MimeBodyPart")
>> > >     [exec] Warning IKVMC0100: class
>> > > "org.bouncycastle.mail.smime.util.FileBackedMimeBodyPart" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Authenticator" not
>> found
>> > >     [exec] Warning IKVMC0100: class
>> "javax.mail.internet.InternetAddress"
>> > > not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Address" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Message$RecipientType"
>> not
>> > > found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Message" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Multipart" not found
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.bouncycastle.mail.smime.util.SharedFileInputStream"
>> > >     [exec]     (missing class "javax.mail.internet.SharedInputStream")
>> > >     [exec] Warning IKVMC0100: class
>> > > "org.bouncycastle.mail.smime.util.SharedFileInputStream" not found
>> > >     [exec] Warning IKVMC0100: class "javax.mail.Transport" not found
>> > >     [echo] Building FontBox
>> > >     [echo] Building JempBox
>> > >     [echo] Building PDFBox
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.TestAll"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.ant.PDFToTextTask"
>> > >     [exec]     (missing class "org.apache.tools.ant.Task")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.cos.TestCOSString"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.encryption.TestPublicKeyEncryption"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.filter.TestFilters"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.pdfparser.TestPDFParser"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0100: class
>> > > "org.apache.pdfbox.pdfparser.TestPDFParser" not found
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.pdmodel.TestFDF"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.pdmodel.interactive.form.TestFields"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0100: class "com.ibm.icu.text.Bidi" not found
>> > >     [exec] Warning IKVMC0100: class "com.ibm.icu.text.Normalizer" not
>> found
>> > >     [exec] Warning IKVMC0100: class "com.ibm.icu.text.Normalizer$Mode"
>> not
>> > > found
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.util.TestDateUtil"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.util.TestPDFToImage"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0100: class
>> "org.apache.pdfbox.util.TestPDFToImage"
>> > > not found
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.util.TestTextStripper"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0100: class
>> > > "org.apache.pdfbox.util.TestTextStripper" not found
>> > >     [exec] Warning IKVMC0105: unable to compile class
>> > > "org.apache.pdfbox.util.TestTextStripperPerformance"
>> > >     [exec]     (missing class "junit.framework.TestCase")
>> > >     [exec] Warning IKVMC0100: class
>> > > "org.apache.pdfbox.util.TestTextStripperPerformance" not found
>> > >     [echo] Building Decrypt
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.Decrypt"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.Decrypt"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.Encrypt"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.Encrypt"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.ExportFDF"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.ExportFDF"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.ExportXFDF"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> > > "org.apache.pdfbox.ExportXFDF"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.ExtractImages"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> > > "org.apache.pdfbox.ExtractImages"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.ExtractText"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> > > "org.apache.pdfbox.ExtractText"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.ImportFDF"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.ImportFDF"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.ImportXFDF"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> > > "org.apache.pdfbox.ImportXFDF"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.Overlay"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.Overlay"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.PDFSplit"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.PDFSplit"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >     [exec] Note IKVMC0001: found main method in class
>> > > "org.apache.pdfbox.PDFReader"
>> > >     [exec] Warning IKVMC0109: skipping class:
>> "org.apache.pdfbox.PDFReader"
>> > >     [exec]     (class is already available in referenced assembly
>> > > "apache-pdfbox-0.8.0-incubator-dev, Version=0.0.0.0, Culture=neutral,
>> > > PublicKeyToken=null")
>> > >
>> > > BUILD SUCCESSFUL
>> > > Total time: 45 seconds
>> > >
>> > > I've attached my changes. Maybe that gets someone started.
>> > >
>> > > > > Also, is there any need to try to build the JAI stuff?  I think
>> we're
>> > > done
>> > > > > w/ JAI.  If so, is there any objection if I remove that from  the
>> > > build.NET
>> > > > > target?
>> > > > The direct dependency to JAI is removed, but if e.g. tiff-support is
>> > > > needed to embed an image you have to use an optional plugin like
>> JAI.
>> > >
>> > > Or just the JAI Image I/O Tools in the classpath which add a
>> > > ImageIO-compatible TIFF codec.
>> > >
>> > > > Jeremias suggested some time ago to remove that plugin stuff and use
>> > > > e.g. sanselan instead and I think that's a good idea. In answer to
>> your
>> > > > question I guess we still need that JAI-stuff, except we don't want
>> to
>> > > > support tiffs using ikvm.
>> > >
>> > > I guess the Java-only part of the JAI Image I/O tools could probably
>> be
>> > > compiled to a .NET DLL, too.
>> > >
>> > >
>> > >
>> > > Jeremias Maerki
>> > >
>>
>>
>>
>>
>> Jeremias Maerki
>>
>>
>

Reply via email to