www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.dwt - Unexpected OPTLINK Termination while building dwt helloworld

reply "Zhenya" <zheny list.ru> writes:
Hi!

As usual, I have everything not as it should :)

I have built dwt.After that I have created MS VS solution,in 
which I have configured paths.And when I was trying to build 
helloworld,I received messagebox
with this stuff:Unexpected OPTLINK Termination at EIP = 00428DA3

Tell me please,what should I do to fix it?
Oct 31 2012
next sibling parent reply Jacob Carlborg <doob me.com> writes:
On 2012-10-31 11:42, Zhenya wrote:
 Hi!

 As usual, I have everything not as it should :)

 I have built dwt.After that I have created MS VS solution,in which I
 have configured paths.And when I was trying to build helloworld,I
 received messagebox
 with this stuff:Unexpected OPTLINK Termination at EIP = 00428DA3

 Tell me please,what should I do to fix it?

What you usually can do is try to pass the files in a different order to the compiler/linker. Also try different flags. I'm not very familiar with the Windows platform, try posting a the learn or main D newsgroup. If that fails there's an alternative linker, called "ulink" or similar, that you could try. -- /Jacob Carlborg
Oct 31 2012
parent reply Jacob Carlborg <doob me.com> writes:
On 2012-10-31 16:08, Zhenya wrote:

 Thank you)
 Maybe I will try it,although I do not know how.

1. Create a new folder, "dlang" 2. In the dlang folder clone DMD, druntime and Phobos using this command "git clone <address>" where "<address>" is one of the git addresses below 3. Install DVM 4. From dlang run "dvm compile ." 5. You will have a compiled binary in dlang\dmd\bin32\dmd DMD: git://github.com/D-Programming-Language/dmd.git druntime: git://github.com/D-Programming-Language/druntime.git Phobos: git://github.com/D-Programming-Language/phobos.git DVM: https://bitbucket.org/doob/dvm/wiki/Home -- /Jacob Carlborg
Oct 31 2012
next sibling parent Jacob Carlborg <doob me.com> writes:
On 2012-11-01 18:09, Zhenya wrote:

 It's a magic.I didn't nothing but now it works.
 )

Strange, but great that it works :) -- /Jacob Carlborg
Nov 01 2012
prev sibling parent reply Jacob Carlborg <doob me.com> writes:
On 2012-11-02 16:13, Zhenya wrote:

 I'm sorry that I didn't I have not noticed the details

Optlink can be very fragile sometime with these details, it's a known problem. There's already an alpha available of DMD that uses the Microsoft linker. -- /Jacob Carlborg
Nov 02 2012
parent Jacob Carlborg <doob me.com> writes:
On 2012-11-02 21:28, Oleg Kuporosov wrote:

 Jacob, it is 64-bit only, not sure DWT is ready for 64.

Right, good point, it's not. More reason to make it ready for 64bit, any help is welcome :) . -- /Jacob Carlborg
Nov 03 2012
prev sibling next sibling parent "cal" <callumenator gmail.com> writes:
On Wednesday, 31 October 2012 at 12:01:11 UTC, Jacob Carlborg 
wrote:
 On 2012-10-31 11:42, Zhenya wrote:
 Hi!

 As usual, I have everything not as it should :)

 I have built dwt.After that I have created MS VS solution,in 
 which I


 have configured paths.And when I was trying to build 
 helloworld,I
 received messagebox
 with this stuff:Unexpected OPTLINK Termination at EIP = 
 00428DA3

 Tell me please,what should I do to fix it


If you're comfortable building dmd, the latest git head has a fix for a similar issue and is worth a try.
Oct 31 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Wednesday, 31 October 2012 at 14:33:05 UTC, cal wrote:
 On Wednesday, 31 October 2012 at 12:01:11 UTC, Jacob Carlborg 
 wrote:
 On 2012-10-31 11:42, Zhenya wrote:
 Hi!

 As usual, I have everything not as it should :)

 I have built dwt.After that I have created MS VS solution,in 
 which I


 have configured paths.And when I was trying to build 
 helloworld,I
 received messagebox
 with this stuff:Unexpected OPTLINK Termination at EIP = 
 00428DA3

 Tell me please,what should I do to fix it


If you're comfortable building dmd, the latest git head has a fix for a similar issue and is worth a try.

Thank you) Maybe I will try it,although I do not know how.
Oct 31 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Wednesday, 31 October 2012 at 18:05:07 UTC, Jacob Carlborg 
wrote:
 On 2012-10-31 16:08, Zhenya wrote:

 Thank you)
 Maybe I will try it,although I do not know how.

1. Create a new folder, "dlang" 2. In the dlang folder clone DMD, druntime and Phobos using this command "git clone <address>" where "<address>" is one of the git addresses below 3. Install DVM 4. From dlang run "dvm compile ." 5. You will have a compiled binary in dlang\dmd\bin32\dmd DMD: git://github.com/D-Programming-Language/dmd.git druntime: git://github.com/D-Programming-Language/druntime.git Phobos: git://github.com/D-Programming-Language/phobos.git DVM: https://bitbucket.org/doob/dvm/wiki/Home

Thank you very much:)
Oct 31 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Wednesday, 31 October 2012 at 18:48:20 UTC, Zhenya wrote:
 On Wednesday, 31 October 2012 at 18:05:07 UTC, Jacob Carlborg 
 wrote:
 On 2012-10-31 16:08, Zhenya wrote:

 Thank you)
 Maybe I will try it,although I do not know how.

1. Create a new folder, "dlang" 2. In the dlang folder clone DMD, druntime and Phobos using this command "git clone <address>" where "<address>" is one of the git addresses below 3. Install DVM 4. From dlang run "dvm compile ." 5. You will have a compiled binary in dlang\dmd\bin32\dmd DMD: git://github.com/D-Programming-Language/dmd.git druntime: git://github.com/D-Programming-Language/druntime.git Phobos: git://github.com/D-Programming-Language/phobos.git DVM: https://bitbucket.org/doob/dvm/wiki/Home

Thank you very much:)

Unfortunally this don't help.If anybody build dwt heloworld under windows succesfully,write please short howto.
Oct 31 2012
prev sibling next sibling parent "Oleg Kuporosov" <Oleg.Kuporosov gmail.com> writes:
        Hi Zhenya
 Unfortunally this don't help.If anybody build dwt heloworld 
 under windows succesfully,write please short howto.

I'd build dwt and snippets successfully under Win7-64, dmd2.060 like several weeks ago, I mostly followed procedure by https://github.com/d-widget-toolkit/dwt. I could not recall any specific actions in addition. Thanks, Oleg.
Nov 01 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Thursday, 1 November 2012 at 09:39:17 UTC, Oleg Kuporosov 
wrote:
        Hi Zhenya
 Unfortunally this don't help.If anybody build dwt heloworld 
 under windows succesfully,write please short howto.

I'd build dwt and snippets successfully under Win7-64, dmd2.060 like several weeks ago, I mostly followed procedure by https://github.com/d-widget-toolkit/dwt. I could not recall any specific actions in addition. Thanks, Oleg.

I also built dwt,but I can't build any program with it,becouse linker says: test.obj(test) Offset 000E5H Record Type 0088 Error 118: Filename Expected D:/Zhenya/Programming/DProgramming/DWT/dwt/lib/dwt-base
Nov 01 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Thursday, 1 November 2012 at 16:51:00 UTC, Zhenya wrote:
 On Thursday, 1 November 2012 at 09:39:17 UTC, Oleg Kuporosov 
 wrote:
       Hi Zhenya
 Unfortunally this don't help.If anybody build dwt heloworld 
 under windows succesfully,write please short howto.

I'd build dwt and snippets successfully under Win7-64, dmd2.060 like several weeks ago, I mostly followed procedure by https://github.com/d-widget-toolkit/dwt. I could not recall any specific actions in addition. Thanks, Oleg.

I also built dwt,but I can't build any program with it,becouse linker says: test.obj(test) Offset 000E5H Record Type 0088 Error 118: Filename Expected D:/Zhenya/Programming/DProgramming/DWT/dwt/lib/dwt-base

It's a magic.I didn't nothing but now it works. )
Nov 01 2012
prev sibling next sibling parent "Oleg Kuporosov" <Oleg.Kuporosov gmail.com> writes:
 It's a magic.I didn't nothing but now it works.

There is no magic, sorry, but something changed. Analyze it! It may help all of us in the future. Oleg.
Nov 02 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Friday, 2 November 2012 at 07:48:30 UTC, Oleg Kuporosov wrote:
 It's a magic.I didn't nothing but now it works.

There is no magic, sorry, but something changed. Analyze it! It may help all of us in the future. Oleg.

I saw that the last error caused by pragma(lib,"../dwt/lib/dwt-base.lib"); But path is valid
Nov 02 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Friday, 2 November 2012 at 15:02:29 UTC, Zhenya wrote:
 On Friday, 2 November 2012 at 07:48:30 UTC, Oleg Kuporosov 
 wrote:
 It's a magic.I didn't nothing but now it works.

There is no magic, sorry, but something changed. Analyze it! It may help all of us in the future. Oleg.


I build it with debug version of swt.Right, there is no magic)
Nov 02 2012
prev sibling next sibling parent "Zhenya" <zheny list.ru> writes:
On Friday, 2 November 2012 at 15:07:02 UTC, Zhenya wrote:
 On Friday, 2 November 2012 at 15:02:29 UTC, Zhenya wrote:
 On Friday, 2 November 2012 at 07:48:30 UTC, Oleg Kuporosov 
 wrote:
 It's a magic.I didn't nothing but now it works.

There is no magic, sorry, but something changed. Analyze it! It may help all of us in the future. Oleg.


when I build it with debug version of swt.Right, there is no magic)

I'm sorry that I didn't I have not noticed the details
Nov 02 2012
prev sibling next sibling parent "Oleg Kuporosov" <Oleg.Kuporosov gmail.com> writes:
 Optlink can be very fragile sometime with these details, it's a 
 known problem. There's already an alpha available of DMD that 
 uses the Microsoft linker.

Jacob, it is 64-bit only, not sure DWT is ready for 64. Oleg.
Nov 02 2012
prev sibling next sibling parent "Oleg Kuporosov" <Oleg.Kuporosov gmail.com> writes:
 What you usually can do is try to pass the files in a different 
 order to the compiler/linker. Also try different flags. I'm not 
 very familiar with the Windows platform, try posting a the 
 learn or main D newsgroup. If that fails there's an alternative 
 linker, called "ulink" or similar, that you could try.

It's probably Unilink: ftp://ftp.styx.cabel.net/pub/UniLink/ I didn't have a chance use it. Thanks, Oleg.
Nov 02 2012
prev sibling parent reply "Kapps" <opantm2+spam gmail.com> writes:
On Wednesday, 31 October 2012 at 10:42:05 UTC, Zhenya wrote:
 Hi!

 As usual, I have everything not as it should :)

 I have built dwt.After that I have created MS VS solution,in 
 which I have configured paths.And when I was trying to build 
 helloworld,I received messagebox
 with this stuff:Unexpected OPTLINK Termination at EIP = 00428DA3

 Tell me please,what should I do to fix it?

http://d.puremagic.com/issues/show_bug.cgi?id=6144 An astoundingly annoying bug, but I've never found any alternative besides randomly changing things and hoping that Optlink accepts it. It's probably the most annoying bug I've ever found while using DMD simply because there's no easy workaround and it only seems to manifest itself in large applications. Luckily, not an issue on Linux or with GDC.
Nov 02 2012
parent Jacob Carlborg <doob me.com> writes:
On 2012-11-02 22:46, Kapps wrote:

 http://d.puremagic.com/issues/show_bug.cgi?id=6144

 An astoundingly annoying bug, but I've never found any alternative
 besides randomly changing things and hoping that Optlink accepts it.
 It's probably the most annoying bug I've ever found while using DMD
 simply because there's no easy workaround and it only seems to manifest
 itself in large applications. Luckily, not an issue on Linux or with GDC.

Yeah, it's only DMD on Windows that suffers this problem. -- /Jacob Carlborg
Nov 03 2012