October 17, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266


Brad Anderson <eco@gnuk.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Attachment #1266|0                           |1
        is obsolete|                            |


--- Comment #20 from Brad Anderson <eco@gnuk.net> 2013-10-16 23:23:58 PDT ---
Created an attachment (id=1268)
New sc.ini (try 3)

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 17, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #21 from Brad Anderson <eco@gnuk.net> 2013-10-16 23:26:33 PDT ---
Just attached a new version which I feel a lot better about. Simpler for the installer to modify and should work with all versions of the VS Command Prompt. It's also much easier for end users to manually configure.

Here it is inline:

---
[Version]
version=7.51 Build 020

; environment for both 32/64 bit
[Environment]
DFLAGS="-I%@P%\..\..\src\phobos" "-I%@P%\..\..\src\druntime\import"


[Environment32]
LIB="%@P%\..\lib"
LINKCMD=%@P%\link.exe


[Environment64]

LIB="%@P%\..\lib64"

; needed to avoid COMDAT folding (bugzilla 10664)
DFLAGS=%DFLAGS% -L/OPT:NOICF

; default to 32-bit linker (can generate 64-bit code) that has a common path
; for VS2010, VS2012, and VS2013. This will be overridden below if the
; installer detects VS.
LINKCMD=%VCINSTALLDIR%\bin\link.exe

; -----------------------------------------------------------------------------
; This enclosed section is specially crafted to be activated by the Windows
; installer when it detects the actual paths to VC and SDK installations so
; modify this in the default sc.ini within the git repo with care
;
; End users: You can fill in the path to VC and Windows SDK and uncomment out
; the appropriate LINKCMD to manually enable support

; Windows installer replaces the following lines with the actual paths
;VCINSTALLDIR=
;WindowsSdkDir=

; Windows installer uncomments the version detected
;VC2013 LINKCMD=%VCINSTALLDIR%\bin\x86_amd64\link.exe
;VC2012 LINKCMD=%VCINSTALLDIR%\bin\x86_amd64\link.exe
;VC2010 LINKCMD=%VCINSTALLDIR%\bin\amd64\link.exe

; ----------------------------------------------------------------------------

; needed with /DEBUG to find mspdb*.dll (only for VS2012 or VS2013) PATH=%PATH%;%VCINSTALLDIR%\bin\x86_amd64;%VCINSTALLDIR%\..\Common7\IDE PATH=%PATH%;%VCINSTALLDIR%\..\Common7\IDE

; Add the library subdirectories of all VC and Windows SDK versions so things ; just work for users using dmd from the VS 64-bit Command Prompt

; C Runtime libraries
LIB=%LIB%;"%VCINSTALLDIR%\lib\amd64"

; Platform libraries (Windows SDK 8)
LIB=%LIB%;"%WindowsSdkDir%\Lib\win8\um\x64"

; Platform libraries (Windows SDK 7)
LIB=%LIB%;"%WindowsSdkDir%\Lib\x64"

---

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 17, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #22 from Rainer Schuetze <r.sagitario@gmx.de> 2013-10-17 00:33:38 PDT ---
Looks nice. One more nitpick:

> ; needed with /DEBUG to find mspdb*.dll (only for VS2012 or VS2013) PATH=%PATH%;%VCINSTALLDIR%\bin\x86_amd64;%VCINSTALLDIR%\..\Common7\IDE PATH=%PATH%;%VCINSTALLDIR%\..\Common7\IDE

This adds %VCINSTALLDIR%\..\Common7\IDE twice.

With running the 32-bit linker, adding an x64 path to PATH might be troublesome. I currently don't have a full VS2012 installation to test whether it actually causes problems.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 17, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #23 from Brad Anderson <eco@gnuk.net> 2013-10-17 12:29:27 PDT ---
(In reply to comment #22)
> Looks nice. One more nitpick:
> 
> > ; needed with /DEBUG to find mspdb*.dll (only for VS2012 or VS2013) PATH=%PATH%;%VCINSTALLDIR%\bin\x86_amd64;%VCINSTALLDIR%\..\Common7\IDE PATH=%PATH%;%VCINSTALLDIR%\..\Common7\IDE
> 
> This adds %VCINSTALLDIR%\..\Common7\IDE twice.
> 

Oops.

> With running the 32-bit linker, adding an x64 path to PATH might be troublesome. I currently don't have a full VS2012 installation to test whether it actually causes problems.

I originally had those enabled by the installer but decided to just define them
always instead to keep the number of changes the compiler must do to a minimum.
 I'll make those enabled by the installer again in the next iteration.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 19, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #24 from Rainer Schuetze <r.sagitario@gmx.de> 2013-10-19 01:10:00 PDT ---
(In reply to comment #21)
> [Environment32]
> LIB="%@P%\..\lib"
> LINKCMD=%@P%\link.exe

I just noticed that calling optlink directly is affected by this change as it also reads LIB from the [Environment] section in sc.ini. Ugly, but I guess we should add the LIB setting there, too.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 20, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #25 from Brad Anderson <eco@gnuk.net> 2013-10-19 18:50:13 PDT ---
(In reply to comment #24)
> (In reply to comment #21)
> > [Environment32]
> > LIB="%@P%\..\lib"
> > LINKCMD=%@P%\link.exe
> 
> I just noticed that calling optlink directly is affected by this change as it also reads LIB from the [Environment] section in sc.ini. Ugly, but I guess we should add the LIB setting there, too.

I'm glad you noticed that.  I'll incorporate it.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 20, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266


Brad Anderson <eco@gnuk.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Attachment #1268|0                           |1
        is obsolete|                            |


--- Comment #26 from Brad Anderson <eco@gnuk.net> 2013-10-19 19:51:21 PDT ---
Created an attachment (id=1271)
New sc.ini (try 4)

Attached is what I think is the final version. I'll make it into a pull request shortly. Inline:

---
[Version]
version=7.51 Build 020


; environment for both 32/64 bit
[Environment]
DFLAGS="-I%@P%\..\..\src\phobos" "-I%@P%\..\..\src\druntime\import"

; optlink only reads from the Environment section so we need this redundancy
; from the Environment32 section (bugzilla 11302)
LIB="%@P%\..\lib"


[Environment32]
LIB="%@P%\..\lib"
LINKCMD=%@P%\link.exe


[Environment64]
LIB="%@P%\..\lib64"

; needed to avoid COMDAT folding (bugzilla 10664)
DFLAGS=%DFLAGS% -L/OPT:NOICF

; default to 32-bit linker (can generate 64-bit code) that has a common path
; for VS2008, VS2010, VS2012, and VS2013. This will be overridden below if the
; installer detects VS.
LINKCMD=%VCINSTALLDIR%\bin\link.exe


; -----------------------------------------------------------------------------
; This enclosed section is specially crafted to be activated by the Windows
; installer when it detects the actual paths to VC and SDK installations so
; modify this in the default sc.ini within the dmd git repo with care.
;
; End users: You can fill in the path to VC and Windows SDK and uncomment out
; the appropriate LINKCMD to manually enable support yourself.
;
; Users using Visual Studio 2010 Express with SDK 7.0A: The installer cannot
; determine the path to the 64-bit compiler included with SDK 7.0A. It's
; recommended to install the Windows SDK 7.1A. Alternatively you can set
; LINKCMD as the path to link.exe SDK 7.0A installs. It would typically be:
;   C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\amd64\link.exe


; Windows installer replaces the following lines with the actual paths
;VCINSTALLDIR=
;WindowsSdkDir=

; - Windows installer uncomments the version detected
;VC2013 LINKCMD=%VCINSTALLDIR%\bin\x86_amd64\link.exe
;VC2012 LINKCMD=%VCINSTALLDIR%\bin\x86_amd64\link.exe
;VC2010 LINKCMD=%VCINSTALLDIR%\bin\amd64\link.exe
;VC2008 LINKCMD=%VCINSTALLDIR%\bin\amd64\link.exe

; needed with /DEBUG to find mspdb*.dll (only for VS2012 or VS2013)
;VC2013 PATH=%PATH%;%VCINSTALLDIR%\bin\x86_amd64;%VCINSTALLDIR%\..\Common7\IDE
;VC2012 PATH=%PATH%;%VCINSTALLDIR%\bin\x86_amd64;%VCINSTALLDIR%\..\Common7\IDE

; ----------------------------------------------------------------------------


; Add the library subdirectories of all VC and Windows SDK versions so things ; just work for users using dmd from the VS 64-bit Command Prompt

; C Runtime libraries
LIB=%LIB%;"%VCINSTALLDIR%\lib\amd64"

; Platform libraries (Windows SDK 8)
LIB=%LIB%;"%WindowsSdkDir%\Lib\win8\um\x64"

; Platform libraries (Windows SDK 7 and 6)
LIB=%LIB%;"%WindowsSdkDir%\Lib\x64"

---

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 20, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #27 from Brad Anderson <eco@gnuk.net> 2013-10-19 20:20:59 PDT ---
https://github.com/D-Programming-Language/dmd/pull/2684

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 20, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266



--- Comment #28 from github-bugzilla@puremagic.com 2013-10-19 21:03:38 PDT ---
Commit pushed to 2.064 at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/2d11aa4311eb2356c759dcd5fa38b046adbb11de New sc.ini with expanded 64-bit support

Note: Requires phobos64.lib to be in lib64 rather than lib

Fixes issue #11266

Should work for all versions of Visual Studio 2008+ when dmd is used within the Visual Studio Command Prompt.

Works in conjunction with the Windows dmd installer to automatically set appropriate paths so 64-bit dmd compilation can be used outside of the Visual Studio Command Prompt

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
October 20, 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11266


Walter Bright <bugzilla@digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
1 2 3
Next ›   Last »