(Cross-)Compiling for windows

classic Classic list List threaded Threaded
15 messages Options
Reply | Threaded
Open this post in threaded view
|

(Cross-)Compiling for windows

Mat Arge
Hy!

I would like to build opensc (and the installer) for windows, preferably cross
compiling it under Linux. Are there and docs available for that. I couldn't
find anything in the github wiki and the available ones in the old wiki on
opensc-project.org are very sparse and a bit outdated (for example, the
win32/installer_from_build.sh script still tries to access the old subversion
server).

cheers
Mat
------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing
conversations that shape the rapidly evolving mobile landscape. Sign up now.
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
You can try and use this[1] branch, not sure it is up to date.

[1] https://github.com/alonbl/openvpn-build/tree/opensc

On Tue, Nov 26, 2013 at 1:27 PM, Mat Arge <[hidden email]> wrote:

> Hy!
>
> I would like to build opensc (and the installer) for windows, preferably cross
> compiling it under Linux. Are there and docs available for that. I couldn't
> find anything in the github wiki and the available ones in the old wiki on
> opensc-project.org are very sparse and a bit outdated (for example, the
> win32/installer_from_build.sh script still tries to access the old subversion
> server).
>
> cheers
> Mat
> ------------------------------------------------------------------------------
> Shape the Mobile Experience: Free Subscription
> Software experts and developers: Be at the forefront of tech innovation.
> Intel(R) Software Adrenaline delivers strategic insight and game-changing
> conversations that shape the rapidly evolving mobile landscape. Sign up now.
> http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
> _______________________________________________
> Opensc-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/opensc-devel
>

------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing
conversations that shape the rapidly evolving mobile landscape. Sign up now.
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Mat Arge
That one builds fine. I tried copying the host and build settings for building
opensc, but I am currently stuck at the compilation of reader-pcsc.c
(respectively its include internal-winscard.h) which fails to include
wintypes.h/windef.h and thus is missing the typedefs for BYTE, DWORD and the
like:

In file included from reader-pcsc.c:38:0:
internal-winscard.h:74:1: error: unknown type name 'BYTE'

cheers
Mat


On Tuesday 26. November 2013 13:57:04 you wrote:

> You can try and use this[1] branch, not sure it is up to date.
>
> [1] https://github.com/alonbl/openvpn-build/tree/opensc
>
> On Tue, Nov 26, 2013 at 1:27 PM, Mat Arge <[hidden email]> wrote:
> > Hy!
> >
> > I would like to build opensc (and the installer) for windows, preferably
> > cross compiling it under Linux. Are there and docs available for that. I
> > couldn't find anything in the github wiki and the available ones in the
> > old wiki on opensc-project.org are very sparse and a bit outdated (for
> > example, the win32/installer_from_build.sh script still tries to access
> > the old subversion server).
> >
> > cheers
> > Mat
> > --------------------------------------------------------------------------
> > ---- Shape the Mobile Experience: Free Subscription
> > Software experts and developers: Be at the forefront of tech innovation.
> > Intel(R) Software Adrenaline delivers strategic insight and game-changing
> > conversations that shape the rapidly evolving mobile landscape. Sign up
> > now.
> > http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clkt
> > rk _______________________________________________
> > Opensc-devel mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/opensc-devel

------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing
conversations that shape the rapidly evolving mobile landscape. Sign up now.
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
On Tue, Nov 26, 2013 at 3:25 PM, Mat Arge <[hidden email]> wrote:
> That one builds fine. I tried copying the host and build settings for building
> opensc, but I am currently stuck at the compilation of reader-pcsc.c
> (respectively its include internal-winscard.h) which fails to include
> wintypes.h/windef.h and thus is missing the typedefs for BYTE, DWORD and the
> like:
>
> In file included from reader-pcsc.c:38:0:
> internal-winscard.h:74:1: error: unknown type name 'BYTE'

Not sure what is 'one builds' and what is 'tried copying the host'.
You should just execute ./build and have it built, disable the libp11
and engine_pkcs11 to have only opensc.

cd generic
IMAGEROOT=`pwd`/image-win64 CHOST=x86_64-w64-mingw32
CBUILD=x86_64-pc-linux-gnu ./build


>
> cheers
> Mat
>
>
> On Tuesday 26. November 2013 13:57:04 you wrote:
>> You can try and use this[1] branch, not sure it is up to date.
>>
>> [1] https://github.com/alonbl/openvpn-build/tree/opensc
>>
>> On Tue, Nov 26, 2013 at 1:27 PM, Mat Arge <[hidden email]> wrote:
>> > Hy!
>> >
>> > I would like to build opensc (and the installer) for windows, preferably
>> > cross compiling it under Linux. Are there and docs available for that. I
>> > couldn't find anything in the github wiki and the available ones in the
>> > old wiki on opensc-project.org are very sparse and a bit outdated (for
>> > example, the win32/installer_from_build.sh script still tries to access
>> > the old subversion server).
>> >
>> > cheers
>> > Mat
>> > --------------------------------------------------------------------------
>> > ---- Shape the Mobile Experience: Free Subscription
>> > Software experts and developers: Be at the forefront of tech innovation.
>> > Intel(R) Software Adrenaline delivers strategic insight and game-changing
>> > conversations that shape the rapidly evolving mobile landscape. Sign up
>> > now.
>> > http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clkt
>> > rk _______________________________________________
>> > Opensc-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/opensc-devel
>
> ------------------------------------------------------------------------------
> Shape the Mobile Experience: Free Subscription
> Software experts and developers: Be at the forefront of tech innovation.
> Intel(R) Software Adrenaline delivers strategic insight and game-changing
> conversations that shape the rapidly evolving mobile landscape. Sign up now.
> http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
> _______________________________________________
> Opensc-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/opensc-devel
>

------------------------------------------------------------------------------
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing
conversations that shape the rapidly evolving mobile landscape. Sign up now.
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Mat Arge
Ah, my bad. I checked out the wrong branch and ended up building openvpn
instead of opensc. But I got it working now, thanks.
What I still cannot accomplish though, is building the minidriver. If I add --
enable-minidriver to the configure options of opensc I get the error

checking cardmod.h usability... no
checking cardmod.h presence... yes
configure: WARNING: cardmod.h: present but cannot be compiled
configure: WARNING: cardmod.h:     check for missing prerequisite headers?
configure: WARNING: cardmod.h: see the Autoconf documentation
configure: WARNING: cardmod.h:     section "Present But Cannot Be Compiled"
configure: WARNING: cardmod.h: proceeding with the compiler's result
checking for cardmod.h... no
configure: error: cardmod.h is not found and required for minidriver

When I check config.log I find that the corresponding test (for cardmod.h's
usability) fails to include wintypes.h/windef.h and fails to know DWORD, BYTE
and such.

cheers
Mat

On Tuesday 26. November 2013 15:34:40 Alon Bar-Lev wrote:

> On Tue, Nov 26, 2013 at 3:25 PM, Mat Arge <[hidden email]> wrote:
> > That one builds fine. I tried copying the host and build settings for
> > building opensc, but I am currently stuck at the compilation of
> > reader-pcsc.c (respectively its include internal-winscard.h) which fails
> > to include wintypes.h/windef.h and thus is missing the typedefs for BYTE,
> > DWORD and the like:
> >
> > In file included from reader-pcsc.c:38:0:
> > internal-winscard.h:74:1: error: unknown type name 'BYTE'
>
> Not sure what is 'one builds' and what is 'tried copying the host'.
> You should just execute ./build and have it built, disable the libp11
> and engine_pkcs11 to have only opensc.
>
> cd generic
> IMAGEROOT=`pwd`/image-win64 CHOST=x86_64-w64-mingw32
> CBUILD=x86_64-pc-linux-gnu ./build
>
> > cheers
> > Mat
> >
> > On Tuesday 26. November 2013 13:57:04 you wrote:
> >> You can try and use this[1] branch, not sure it is up to date.
> >>
> >> [1] https://github.com/alonbl/openvpn-build/tree/opensc
> >>
> >> On Tue, Nov 26, 2013 at 1:27 PM, Mat Arge <[hidden email]> wrote:
> >> > Hy!
> >> >
> >> > I would like to build opensc (and the installer) for windows,
> >> > preferably
> >> > cross compiling it under Linux. Are there and docs available for that.
> >> > I
> >> > couldn't find anything in the github wiki and the available ones in the
> >> > old wiki on opensc-project.org are very sparse and a bit outdated (for
> >> > example, the win32/installer_from_build.sh script still tries to access
> >> > the old subversion server).
> >> >
> >> > cheers
> >> > Mat

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]> wrote:

> Ah, my bad. I checked out the wrong branch and ended up building openvpn
> instead of opensc. But I got it working now, thanks.
> What I still cannot accomplish though, is building the minidriver. If I add --
> enable-minidriver to the configure options of opensc I get the error
>
> checking cardmod.h usability... no
> checking cardmod.h presence... yes
> configure: WARNING: cardmod.h: present but cannot be compiled
> configure: WARNING: cardmod.h:     check for missing prerequisite headers?
> configure: WARNING: cardmod.h: see the Autoconf documentation
> configure: WARNING: cardmod.h:     section "Present But Cannot Be Compiled"
> configure: WARNING: cardmod.h: proceeding with the compiler's result
> checking for cardmod.h... no
> configure: error: cardmod.h is not found and required for minidriver
>
> When I check config.log I find that the corresponding test (for cardmod.h's
> usability) fails to include wintypes.h/windef.h and fails to know DWORD, BYTE
> and such.

Maybe you need to fix reintegrate[1], this is old one... long time
since I done this.
And copy out the cardmod.h into own directory with dummy wintypes.h.
Not sure what changed in this header since then.


[1] https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-compat.h


>
> cheers
> Mat
>
> On Tuesday 26. November 2013 15:34:40 Alon Bar-Lev wrote:
>> On Tue, Nov 26, 2013 at 3:25 PM, Mat Arge <[hidden email]> wrote:
>> > That one builds fine. I tried copying the host and build settings for
>> > building opensc, but I am currently stuck at the compilation of
>> > reader-pcsc.c (respectively its include internal-winscard.h) which fails
>> > to include wintypes.h/windef.h and thus is missing the typedefs for BYTE,
>> > DWORD and the like:
>> >
>> > In file included from reader-pcsc.c:38:0:
>> > internal-winscard.h:74:1: error: unknown type name 'BYTE'
>>
>> Not sure what is 'one builds' and what is 'tried copying the host'.
>> You should just execute ./build and have it built, disable the libp11
>> and engine_pkcs11 to have only opensc.
>>
>> cd generic
>> IMAGEROOT=`pwd`/image-win64 CHOST=x86_64-w64-mingw32
>> CBUILD=x86_64-pc-linux-gnu ./build
>>
>> > cheers
>> > Mat
>> >
>> > On Tuesday 26. November 2013 13:57:04 you wrote:
>> >> You can try and use this[1] branch, not sure it is up to date.
>> >>
>> >> [1] https://github.com/alonbl/openvpn-build/tree/opensc
>> >>
>> >> On Tue, Nov 26, 2013 at 1:27 PM, Mat Arge <[hidden email]> wrote:
>> >> > Hy!
>> >> >
>> >> > I would like to build opensc (and the installer) for windows,
>> >> > preferably
>> >> > cross compiling it under Linux. Are there and docs available for that.
>> >> > I
>> >> > couldn't find anything in the github wiki and the available ones in the
>> >> > old wiki on opensc-project.org are very sparse and a bit outdated (for
>> >> > example, the win32/installer_from_build.sh script still tries to access
>> >> > the old subversion server).
>> >> >
>> >> > cheers
>> >> > Mat
>
>
> ------------------------------------------------------------------------------
> Rapidly troubleshoot problems before they affect your business. Most IT
> organizations don't have a clear picture of how application performance
> affects their revenue. With AppDynamics, you get 100% visibility into your
> Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
> http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
> _______________________________________________
> Opensc-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/opensc-devel
>

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Mat Arge
On Wednesday 27. November 2013 17:32:46 you wrote:

> On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]> wrote:
> > Ah, my bad. I checked out the wrong branch and ended up building openvpn
> > instead of opensc. But I got it working now, thanks.
> > What I still cannot accomplish though, is building the minidriver. If I
> > add -- enable-minidriver to the configure options of opensc I get the
> > error
> >
> > checking cardmod.h usability... no
> > checking cardmod.h presence... yes
> > configure: WARNING: cardmod.h: present but cannot be compiled
> > configure: WARNING: cardmod.h:     check for missing prerequisite headers?
> > configure: WARNING: cardmod.h: see the Autoconf documentation
> > configure: WARNING: cardmod.h:     section "Present But Cannot Be
> > Compiled"
> > configure: WARNING: cardmod.h: proceeding with the compiler's result
> > checking for cardmod.h... no
> > configure: error: cardmod.h is not found and required for minidriver
> >
> > When I check config.log I find that the corresponding test (for
> > cardmod.h's
> > usability) fails to include wintypes.h/windef.h and fails to know DWORD,
> > BYTE and such.
>
> Maybe you need to fix reintegrate[1], this is old one... long time
> since I done this.
> And copy out the cardmod.h into own directory with dummy wintypes.h.
> Not sure what changed in this header since then.
>
>
> [1]
> https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-co
> mpat.h
> > cheers
> > Mat
> >
I'm a bit confused now. Did no one try to build the minidriver in the last
years? Or is this just a mingw/cross compilation problem an building the
minidriver only works for a native windows build?

cheers
Mat
------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]> wrote:

>
> On Wednesday 27. November 2013 17:32:46 you wrote:
> > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]> wrote:
> > > Ah, my bad. I checked out the wrong branch and ended up building openvpn
> > > instead of opensc. But I got it working now, thanks.
> > > What I still cannot accomplish though, is building the minidriver. If I
> > > add -- enable-minidriver to the configure options of opensc I get the
> > > error
> > >
> > > checking cardmod.h usability... no
> > > checking cardmod.h presence... yes
> > > configure: WARNING: cardmod.h: present but cannot be compiled
> > > configure: WARNING: cardmod.h:     check for missing prerequisite headers?
> > > configure: WARNING: cardmod.h: see the Autoconf documentation
> > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
> > > Compiled"
> > > configure: WARNING: cardmod.h: proceeding with the compiler's result
> > > checking for cardmod.h... no
> > > configure: error: cardmod.h is not found and required for minidriver
> > >
> > > When I check config.log I find that the corresponding test (for
> > > cardmod.h's
> > > usability) fails to include wintypes.h/windef.h and fails to know DWORD,
> > > BYTE and such.
> >
> > Maybe you need to fix reintegrate[1], this is old one... long time
> > since I done this.
> > And copy out the cardmod.h into own directory with dummy wintypes.h.
> > Not sure what changed in this header since then.
> >
> >
> > [1]
> > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-co
> > mpat.h
> > > cheers
> > > Mat
> > >
>
> I'm a bit confused now. Did no one try to build the minidriver in the last
> years? Or is this just a mingw/cross compilation problem an building the
> minidriver only works for a native windows build?

I think that in recent years the formal package was compiled using
msvc, per the assumption that at any environment the vendor's compiler
should be used. I do not quite agree with this approach, I think we
should endorse the free alternatives.

Regards,
Alon

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Andreas Jellinghaus-4
For the record, for years I was using MSVC on windows and it was fine to compile OpenSC with it.
Years ago a free edition of VC was made available, so there is no cost for that. I found the alternatives mingw and cygwin clumsy to use and rather cause issues for normal windows end users than help.

But some people actually like cygwin or mingw, what a strange taste :-)

Regards Andreas


2013/11/28 Alon Bar-Lev <[hidden email]>
On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]> wrote:
>
> On Wednesday 27. November 2013 17:32:46 you wrote:
> > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]> wrote:
> > > Ah, my bad. I checked out the wrong branch and ended up building openvpn
> > > instead of opensc. But I got it working now, thanks.
> > > What I still cannot accomplish though, is building the minidriver. If I
> > > add -- enable-minidriver to the configure options of opensc I get the
> > > error
> > >
> > > checking cardmod.h usability... no
> > > checking cardmod.h presence... yes
> > > configure: WARNING: cardmod.h: present but cannot be compiled
> > > configure: WARNING: cardmod.h:     check for missing prerequisite headers?
> > > configure: WARNING: cardmod.h: see the Autoconf documentation
> > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
> > > Compiled"
> > > configure: WARNING: cardmod.h: proceeding with the compiler's result
> > > checking for cardmod.h... no
> > > configure: error: cardmod.h is not found and required for minidriver
> > >
> > > When I check config.log I find that the corresponding test (for
> > > cardmod.h's
> > > usability) fails to include wintypes.h/windef.h and fails to know DWORD,
> > > BYTE and such.
> >
> > Maybe you need to fix reintegrate[1], this is old one... long time
> > since I done this.
> > And copy out the cardmod.h into own directory with dummy wintypes.h.
> > Not sure what changed in this header since then.
> >
> >
> > [1]
> > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-co
> > mpat.h
> > > cheers
> > > Mat
> > >
>
> I'm a bit confused now. Did no one try to build the minidriver in the last
> years? Or is this just a mingw/cross compilation problem an building the
> minidriver only works for a native windows build?

I think that in recent years the formal package was compiled using
msvc, per the assumption that at any environment the vendor's compiler
should be used. I do not quite agree with this approach, I think we
should endorse the free alternatives.

Regards,
Alon

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel


------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
On Thu, Nov 28, 2013 at 10:17 PM, Andreas Jellinghaus
<[hidden email]> wrote:
> For the record, for years I was using MSVC on windows and it was fine to
> compile OpenSC with it.
> Years ago a free edition of VC was made available, so there is no cost for
> that. I found the alternatives mingw and cygwin clumsy to use and rather
> cause issues for normal windows end users than help.
>
> But some people actually like cygwin or mingw, what a strange taste :-)

Right :)

However, apart of taste...

Using mingw or cygwin(with native build option) enables maintaining
single build system, and enables using C99 and such... also easier to
redistribute as it does not need special runtime redistributable.

>
> Regards Andreas
>
>
> 2013/11/28 Alon Bar-Lev <[hidden email]>
>>
>> On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]> wrote:
>> >
>> > On Wednesday 27. November 2013 17:32:46 you wrote:
>> > > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]>
>> > > wrote:
>> > > > Ah, my bad. I checked out the wrong branch and ended up building
>> > > > openvpn
>> > > > instead of opensc. But I got it working now, thanks.
>> > > > What I still cannot accomplish though, is building the minidriver.
>> > > > If I
>> > > > add -- enable-minidriver to the configure options of opensc I get
>> > > > the
>> > > > error
>> > > >
>> > > > checking cardmod.h usability... no
>> > > > checking cardmod.h presence... yes
>> > > > configure: WARNING: cardmod.h: present but cannot be compiled
>> > > > configure: WARNING: cardmod.h:     check for missing prerequisite
>> > > > headers?
>> > > > configure: WARNING: cardmod.h: see the Autoconf documentation
>> > > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
>> > > > Compiled"
>> > > > configure: WARNING: cardmod.h: proceeding with the compiler's result
>> > > > checking for cardmod.h... no
>> > > > configure: error: cardmod.h is not found and required for minidriver
>> > > >
>> > > > When I check config.log I find that the corresponding test (for
>> > > > cardmod.h's
>> > > > usability) fails to include wintypes.h/windef.h and fails to know
>> > > > DWORD,
>> > > > BYTE and such.
>> > >
>> > > Maybe you need to fix reintegrate[1], this is old one... long time
>> > > since I done this.
>> > > And copy out the cardmod.h into own directory with dummy wintypes.h.
>> > > Not sure what changed in this header since then.
>> > >
>> > >
>> > > [1]
>> > >
>> > > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-co
>> > > mpat.h
>> > > > cheers
>> > > > Mat
>> > > >
>> >
>> > I'm a bit confused now. Did no one try to build the minidriver in the
>> > last
>> > years? Or is this just a mingw/cross compilation problem an building the
>> > minidriver only works for a native windows build?
>>
>> I think that in recent years the formal package was compiled using
>> msvc, per the assumption that at any environment the vendor's compiler
>> should be used. I do not quite agree with this approach, I think we
>> should endorse the free alternatives.
>>
>> Regards,
>> Alon
>>
>>
>> ------------------------------------------------------------------------------
>> Rapidly troubleshoot problems before they affect your business. Most IT
>> organizations don't have a clear picture of how application performance
>> affects their revenue. With AppDynamics, you get 100% visibility into your
>> Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics
>> Pro!
>>
>> http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
>> _______________________________________________
>> Opensc-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/opensc-devel
>
>

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Mat Arge
In reply to this post by Andreas Jellinghaus-4
What were the issues caused by a mingw build for Windows users?

cheers
Mat

On Thursday 28. November 2013 21:17:23 Andreas Jellinghaus wrote:

> For the record, for years I was using MSVC on windows and it was fine to
> compile OpenSC with it.
> Years ago a free edition of VC was made available, so there is no cost for
> that. I found the alternatives mingw and cygwin clumsy to use and rather
> cause issues for normal windows end users than help.
>
> But some people actually like cygwin or mingw, what a strange taste :-)
>
> Regards Andreas
>
>
> 2013/11/28 Alon Bar-Lev <[hidden email]>
>
> > On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]> wrote:
> > > On Wednesday 27. November 2013 17:32:46 you wrote:
> > > > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]>
> >
> > wrote:
> > > > > Ah, my bad. I checked out the wrong branch and ended up building
> >
> > openvpn
> >
> > > > > instead of opensc. But I got it working now, thanks.
> > > > > What I still cannot accomplish though, is building the minidriver.
> >
> > If I
> >
> > > > > add -- enable-minidriver to the configure options of opensc I get
> > > > > the
> > > > > error
> > > > >
> > > > > checking cardmod.h usability... no
> > > > > checking cardmod.h presence... yes
> > > > > configure: WARNING: cardmod.h: present but cannot be compiled
> > > > > configure: WARNING: cardmod.h:     check for missing prerequisite
> >
> > headers?
> >
> > > > > configure: WARNING: cardmod.h: see the Autoconf documentation
> > > > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
> > > > > Compiled"
> > > > > configure: WARNING: cardmod.h: proceeding with the compiler's result
> > > > > checking for cardmod.h... no
> > > > > configure: error: cardmod.h is not found and required for minidriver
> > > > >
> > > > > When I check config.log I find that the corresponding test (for
> > > > > cardmod.h's
> > > > > usability) fails to include wintypes.h/windef.h and fails to know
> >
> > DWORD,
> >
> > > > > BYTE and such.
> > > >
> > > > Maybe you need to fix reintegrate[1], this is old one... long time
> > > > since I done this.
> > > > And copy out the cardmod.h into own directory with dummy wintypes.h.
> > > > Not sure what changed in this header since then.
> > > >
> > > >
> > > > [1]
> >
> > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-c
> > o
> >
> > > > mpat.h
> > > >
> > > > > cheers
> > > > > Mat
> > >
> > > I'm a bit confused now. Did no one try to build the minidriver in the
> >
> > last
> >
> > > years? Or is this just a mingw/cross compilation problem an building the
> > > minidriver only works for a native windows build?
> >
> > I think that in recent years the formal package was compiled using
> > msvc, per the assumption that at any environment the vendor's compiler
> > should be used. I do not quite agree with this approach, I think we
> > should endorse the free alternatives.
> >
> > Regards,
> > Alon
> >
> >
> > --------------------------------------------------------------------------
> > ---- Rapidly troubleshoot problems before they affect your business. Most
> > IT organizations don't have a clear picture of how application
> > performance affects their revenue. With AppDynamics, you get 100%
> > visibility into your Java,.NET, & PHP application. Start your 15-day FREE
> > TRIAL of AppDynamics Pro!
> > http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktr
> > k
> > _______________________________________________
> > Opensc-devel mailing list
> > [hidden email]
> > https://lists.sourceforge.net/lists/listinfo/opensc-devel

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
On Fri, Nov 29, 2013 at 10:14 AM, Mat Arge <[hidden email]> wrote:
> What were the issues caused by a mingw build for Windows users?

At that time Andreas speaks of, the autotools build system was
incapable of being used in cross compile mode and code railed on msvc
specifics for Windows support.

This was changed during the build system rewrite[1], so that we could
produce binaries based on mingw, packaging could have made using nsis
for fully non windows build.

But after it was an option, it was not used for formal builds per the
assumption that native compiler is preferred, and two separate build
systems were kept to be maintained.

What I am happy of is that the build was not broken since and is
usable, and I am using it to build my own and help users that need to
integrate with other tools such as openvpn.

Regards,
Alon Bar-Lev

[1] http://opensc.1086184.n5.nabble.com/TEST-REQUEST-OpenSC-Windows-MinGW-based-build-td5392.html

>
> cheers
> Mat
>
> On Thursday 28. November 2013 21:17:23 Andreas Jellinghaus wrote:
>> For the record, for years I was using MSVC on windows and it was fine to
>> compile OpenSC with it.
>> Years ago a free edition of VC was made available, so there is no cost for
>> that. I found the alternatives mingw and cygwin clumsy to use and rather
>> cause issues for normal windows end users than help.
>>
>> But some people actually like cygwin or mingw, what a strange taste :-)
>>
>> Regards Andreas
>>
>>
>> 2013/11/28 Alon Bar-Lev <[hidden email]>
>>
>> > On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]> wrote:
>> > > On Wednesday 27. November 2013 17:32:46 you wrote:
>> > > > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]>
>> >
>> > wrote:
>> > > > > Ah, my bad. I checked out the wrong branch and ended up building
>> >
>> > openvpn
>> >
>> > > > > instead of opensc. But I got it working now, thanks.
>> > > > > What I still cannot accomplish though, is building the minidriver.
>> >
>> > If I
>> >
>> > > > > add -- enable-minidriver to the configure options of opensc I get
>> > > > > the
>> > > > > error
>> > > > >
>> > > > > checking cardmod.h usability... no
>> > > > > checking cardmod.h presence... yes
>> > > > > configure: WARNING: cardmod.h: present but cannot be compiled
>> > > > > configure: WARNING: cardmod.h:     check for missing prerequisite
>> >
>> > headers?
>> >
>> > > > > configure: WARNING: cardmod.h: see the Autoconf documentation
>> > > > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
>> > > > > Compiled"
>> > > > > configure: WARNING: cardmod.h: proceeding with the compiler's result
>> > > > > checking for cardmod.h... no
>> > > > > configure: error: cardmod.h is not found and required for minidriver
>> > > > >
>> > > > > When I check config.log I find that the corresponding test (for
>> > > > > cardmod.h's
>> > > > > usability) fails to include wintypes.h/windef.h and fails to know
>> >
>> > DWORD,
>> >
>> > > > > BYTE and such.
>> > > >
>> > > > Maybe you need to fix reintegrate[1], this is old one... long time
>> > > > since I done this.
>> > > > And copy out the cardmod.h into own directory with dummy wintypes.h.
>> > > > Not sure what changed in this header since then.
>> > > >
>> > > >
>> > > > [1]
>> >
>> > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-mingw-c
>> > o
>> >
>> > > > mpat.h
>> > > >
>> > > > > cheers
>> > > > > Mat
>> > >
>> > > I'm a bit confused now. Did no one try to build the minidriver in the
>> >
>> > last
>> >
>> > > years? Or is this just a mingw/cross compilation problem an building the
>> > > minidriver only works for a native windows build?
>> >
>> > I think that in recent years the formal package was compiled using
>> > msvc, per the assumption that at any environment the vendor's compiler
>> > should be used. I do not quite agree with this approach, I think we
>> > should endorse the free alternatives.
>> >
>> > Regards,
>> > Alon
>> >
>> >
>> > --------------------------------------------------------------------------
>> > ---- Rapidly troubleshoot problems before they affect your business. Most
>> > IT organizations don't have a clear picture of how application
>> > performance affects their revenue. With AppDynamics, you get 100%
>> > visibility into your Java,.NET, & PHP application. Start your 15-day FREE
>> > TRIAL of AppDynamics Pro!
>> > http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktr
>> > k
>> > _______________________________________________
>> > Opensc-devel mailing list
>> > [hidden email]
>> > https://lists.sourceforge.net/lists/listinfo/opensc-devel
>
> ------------------------------------------------------------------------------
> Rapidly troubleshoot problems before they affect your business. Most IT
> organizations don't have a clear picture of how application performance
> affects their revenue. With AppDynamics, you get 100% visibility into your
> Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
> http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
> _______________________________________________
> Opensc-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/opensc-devel
>

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Mat Arge
But the build is broken, as far as the minidriver is concerned.  Im am
currently trying to get it to work, the main problem lies with cardmod.h
because:
* The cardmod.h from mingw seems to be not up to date, it misses some
definitions (MAX_CONTAINER_NAME_LEN, CARD_CACHE_FILE_FORMAT, ...) which are
defines in MS's "Windows Smartcard Minidriver Specification" (current version
7.07)
The cardmod-mingw-compat.h replacement is missing all of those definitions. To
be honest, I don't quite undesrstand how this ever worked.
The official cardmod.h from Windows has some MS-speicific definitions and
doesn't build out-of-the box either.

I found a four year old mailing list discussion which ended in an unfinished
debate about the license of cardmod.h:
http://opensc.1086184.n5.nabble.com/Opensc-minidriver-for-base-csp-td8317.html

The best way I see currently, is to take mingw's cardmod.h and append with the
definitions copied from the MS speicification. Which brings us back to the
legal discusssion above.

cheers
Mat

On Friday 29. November 2013 10:23:52 you wrote:

> On Fri, Nov 29, 2013 at 10:14 AM, Mat Arge <[hidden email]> wrote:
> > What were the issues caused by a mingw build for Windows users?
>
> At that time Andreas speaks of, the autotools build system was
> incapable of being used in cross compile mode and code railed on msvc
> specifics for Windows support.
>
> This was changed during the build system rewrite[1], so that we could
> produce binaries based on mingw, packaging could have made using nsis
> for fully non windows build.
>
> But after it was an option, it was not used for formal builds per the
> assumption that native compiler is preferred, and two separate build
> systems were kept to be maintained.
>
> What I am happy of is that the build was not broken since and is
> usable, and I am using it to build my own and help users that need to
> integrate with other tools such as openvpn.
>
> Regards,
> Alon Bar-Lev
>
> [1]
> http://opensc.1086184.n5.nabble.com/TEST-REQUEST-OpenSC-Windows-MinGW-based
> -build-td5392.html
> > cheers
> > Mat
> >
> > On Thursday 28. November 2013 21:17:23 Andreas Jellinghaus wrote:
> >> For the record, for years I was using MSVC on windows and it was fine to
> >> compile OpenSC with it.
> >> Years ago a free edition of VC was made available, so there is no cost
> >> for
> >> that. I found the alternatives mingw and cygwin clumsy to use and rather
> >> cause issues for normal windows end users than help.
> >>
> >> But some people actually like cygwin or mingw, what a strange taste :-)
> >>
> >> Regards Andreas
> >>
> >>
> >> 2013/11/28 Alon Bar-Lev <[hidden email]>
> >>
> >> > On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]>
wrote:

> >> > > On Wednesday 27. November 2013 17:32:46 you wrote:
> >> > > > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]>
> >> >
> >> > wrote:
> >> > > > > Ah, my bad. I checked out the wrong branch and ended up building
> >> >
> >> > openvpn
> >> >
> >> > > > > instead of opensc. But I got it working now, thanks.
> >> > > > > What I still cannot accomplish though, is building the
> >> > > > > minidriver.
> >> >
> >> > If I
> >> >
> >> > > > > add -- enable-minidriver to the configure options of opensc I get
> >> > > > > the
> >> > > > > error
> >> > > > >
> >> > > > > checking cardmod.h usability... no
> >> > > > > checking cardmod.h presence... yes
> >> > > > > configure: WARNING: cardmod.h: present but cannot be compiled
> >> > > > > configure: WARNING: cardmod.h:     check for missing prerequisite
> >> >
> >> > headers?
> >> >
> >> > > > > configure: WARNING: cardmod.h: see the Autoconf documentation
> >> > > > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
> >> > > > > Compiled"
> >> > > > > configure: WARNING: cardmod.h: proceeding with the compiler's
> >> > > > > result
> >> > > > > checking for cardmod.h... no
> >> > > > > configure: error: cardmod.h is not found and required for
> >> > > > > minidriver
> >> > > > >
> >> > > > > When I check config.log I find that the corresponding test (for
> >> > > > > cardmod.h's
> >> > > > > usability) fails to include wintypes.h/windef.h and fails to know
> >> >
> >> > DWORD,
> >> >
> >> > > > > BYTE and such.
> >> > > >
> >> > > > Maybe you need to fix reintegrate[1], this is old one... long time
> >> > > > since I done this.
> >> > > > And copy out the cardmod.h into own directory with dummy
> >> > > > wintypes.h.
> >> > > > Not sure what changed in this header since then.
> >> > > >
> >> > > >
> >> > > > [1]
> >> >
> >> > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-ming
> >> > w-c
> >> > o
> >> >
> >> > > > mpat.h
> >> > > >
> >> > > > > cheers
> >> > > > > Mat
> >> > >
> >> > > I'm a bit confused now. Did no one try to build the minidriver in the
> >> >
> >> > last
> >> >
> >> > > years? Or is this just a mingw/cross compilation problem an building
> >> > > the
> >> > > minidriver only works for a native windows build?
> >> >
> >> > I think that in recent years the formal package was compiled using
> >> > msvc, per the assumption that at any environment the vendor's compiler
> >> > should be used. I do not quite agree with this approach, I think we
> >> > should endorse the free alternatives.
> >> >
> >> > Regards,
> >> > Alon
> >> >

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Alon Bar-Lev
On Fri, Nov 29, 2013 at 1:26 PM, Mat Arge <[hidden email]> wrote:

> But the build is broken, as far as the minidriver is concerned.  Im am
> currently trying to get it to work, the main problem lies with cardmod.h
> because:
> * The cardmod.h from mingw seems to be not up to date, it misses some
> definitions (MAX_CONTAINER_NAME_LEN, CARD_CACHE_FILE_FORMAT, ...) which are
> defines in MS's "Windows Smartcard Minidriver Specification" (current version
> 7.07)
> The cardmod-mingw-compat.h replacement is missing all of those definitions. To
> be honest, I don't quite undesrstand how this ever worked.
> The official cardmod.h from Windows has some MS-speicific definitions and
> doesn't build out-of-the box either.
>
> I found a four year old mailing list discussion which ended in an unfinished
> debate about the license of cardmod.h:
> http://opensc.1086184.n5.nabble.com/Opensc-minidriver-for-base-csp-td8317.html
>
> The best way I see currently, is to take mingw's cardmod.h and append with the
> definitions copied from the MS speicification. Which brings us back to the
> legal discusssion above.

The effort dropped because of the legal issue.

My stand in that was that the minidriver should be forked into own
project, adding windows specific component into platform independent
component set was a mistake.

Recently I also split off the tap-windows from openvpn per the same reason.

The windows specific component should be built and packaged without
any implication of the platform independent component, using platform
specific tools if required.

In our case, it implies that the coupling between the opensc core and
the cardmod should be much lower. Preferably to use the PKCS#11
interface with some vendor specific extension to complete the missing
functionality due to I think not that good design decision Microsoft
took when building the cardmod interface.

>
> cheers
> Mat
>
> On Friday 29. November 2013 10:23:52 you wrote:
>> On Fri, Nov 29, 2013 at 10:14 AM, Mat Arge <[hidden email]> wrote:
>> > What were the issues caused by a mingw build for Windows users?
>>
>> At that time Andreas speaks of, the autotools build system was
>> incapable of being used in cross compile mode and code railed on msvc
>> specifics for Windows support.
>>
>> This was changed during the build system rewrite[1], so that we could
>> produce binaries based on mingw, packaging could have made using nsis
>> for fully non windows build.
>>
>> But after it was an option, it was not used for formal builds per the
>> assumption that native compiler is preferred, and two separate build
>> systems were kept to be maintained.
>>
>> What I am happy of is that the build was not broken since and is
>> usable, and I am using it to build my own and help users that need to
>> integrate with other tools such as openvpn.
>>
>> Regards,
>> Alon Bar-Lev
>>
>> [1]
>> http://opensc.1086184.n5.nabble.com/TEST-REQUEST-OpenSC-Windows-MinGW-based
>> -build-td5392.html
>> > cheers
>> > Mat
>> >
>> > On Thursday 28. November 2013 21:17:23 Andreas Jellinghaus wrote:
>> >> For the record, for years I was using MSVC on windows and it was fine to
>> >> compile OpenSC with it.
>> >> Years ago a free edition of VC was made available, so there is no cost
>> >> for
>> >> that. I found the alternatives mingw and cygwin clumsy to use and rather
>> >> cause issues for normal windows end users than help.
>> >>
>> >> But some people actually like cygwin or mingw, what a strange taste :-)
>> >>
>> >> Regards Andreas
>> >>
>> >>
>> >> 2013/11/28 Alon Bar-Lev <[hidden email]>
>> >>
>> >> > On Thu, Nov 28, 2013 at 5:23 PM, Mat Arge <[hidden email]>
> wrote:
>> >> > > On Wednesday 27. November 2013 17:32:46 you wrote:
>> >> > > > On Wed, Nov 27, 2013 at 5:09 PM, Mat Arge <[hidden email]>
>> >> >
>> >> > wrote:
>> >> > > > > Ah, my bad. I checked out the wrong branch and ended up building
>> >> >
>> >> > openvpn
>> >> >
>> >> > > > > instead of opensc. But I got it working now, thanks.
>> >> > > > > What I still cannot accomplish though, is building the
>> >> > > > > minidriver.
>> >> >
>> >> > If I
>> >> >
>> >> > > > > add -- enable-minidriver to the configure options of opensc I get
>> >> > > > > the
>> >> > > > > error
>> >> > > > >
>> >> > > > > checking cardmod.h usability... no
>> >> > > > > checking cardmod.h presence... yes
>> >> > > > > configure: WARNING: cardmod.h: present but cannot be compiled
>> >> > > > > configure: WARNING: cardmod.h:     check for missing prerequisite
>> >> >
>> >> > headers?
>> >> >
>> >> > > > > configure: WARNING: cardmod.h: see the Autoconf documentation
>> >> > > > > configure: WARNING: cardmod.h:     section "Present But Cannot Be
>> >> > > > > Compiled"
>> >> > > > > configure: WARNING: cardmod.h: proceeding with the compiler's
>> >> > > > > result
>> >> > > > > checking for cardmod.h... no
>> >> > > > > configure: error: cardmod.h is not found and required for
>> >> > > > > minidriver
>> >> > > > >
>> >> > > > > When I check config.log I find that the corresponding test (for
>> >> > > > > cardmod.h's
>> >> > > > > usability) fails to include wintypes.h/windef.h and fails to know
>> >> >
>> >> > DWORD,
>> >> >
>> >> > > > > BYTE and such.
>> >> > > >
>> >> > > > Maybe you need to fix reintegrate[1], this is old one... long time
>> >> > > > since I done this.
>> >> > > > And copy out the cardmod.h into own directory with dummy
>> >> > > > wintypes.h.
>> >> > > > Not sure what changed in this header since then.
>> >> > > >
>> >> > > >
>> >> > > > [1]
>> >> >
>> >> > https://github.com/alonbl/OpenSC-Build/blob/master/include/cardmod-ming
>> >> > w-c
>> >> > o
>> >> >
>> >> > > > mpat.h
>> >> > > >
>> >> > > > > cheers
>> >> > > > > Mat
>> >> > >
>> >> > > I'm a bit confused now. Did no one try to build the minidriver in the
>> >> >
>> >> > last
>> >> >
>> >> > > years? Or is this just a mingw/cross compilation problem an building
>> >> > > the
>> >> > > minidriver only works for a native windows build?
>> >> >
>> >> > I think that in recent years the formal package was compiled using
>> >> > msvc, per the assumption that at any environment the vendor's compiler
>> >> > should be used. I do not quite agree with this approach, I think we
>> >> > should endorse the free alternatives.
>> >> >
>> >> > Regards,
>> >> > Alon
>> >> >
>
>
> ------------------------------------------------------------------------------
> Rapidly troubleshoot problems before they affect your business. Most IT
> organizations don't have a clear picture of how application performance
> affects their revenue. With AppDynamics, you get 100% visibility into your
> Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
> http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
> _______________________________________________
> Opensc-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/opensc-devel
>

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: (Cross-)Compiling for windows

Mat Arge
Alright. I', about to try to actually build opensc (from the git sources)
under windows, but I am failing miserably so far. The instructions in the old
wiki are neither very helpful nor up to date.


Is there a concise and current howto for building on windows available
somewhere?

cheers
Mat

On Friday 29. November 2013 13:34:53 Alon Bar-Lev wrote:

>
> The effort dropped because of the legal issue.
>
> My stand in that was that the minidriver should be forked into own
> project, adding windows specific component into platform independent
> component set was a mistake.
>
> Recently I also split off the tap-windows from openvpn per the same reason.
>
> The windows specific component should be built and packaged without
> any implication of the platform independent component, using platform
> specific tools if required.
>
> In our case, it implies that the coupling between the opensc core and
> the cardmod should be much lower. Preferably to use the PKCS#11
> interface with some vendor specific extension to complete the missing
> functionality due to I think not that good design decision Microsoft
> took when building the cardmod interface.

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
_______________________________________________
Opensc-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/opensc-devel

signature.asc (679 bytes) Download Attachment