Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Python

missing python-config and building python on Windows

 

 

Python python RSS feed   Index | Next | Previous | View Threaded


dregister at clear

Jul 31, 2012, 5:48 PM

Post #1 of 5 (308 views)
Permalink
missing python-config and building python on Windows

I am attempting to build gtk and glade using mingw/msys. It seems that some
of the packages require python. I installed 2.7.3 using the installer from
python.org. That worked for some of the packages but now I am trying to do
one that needs python-config which I don't find in the installation directory.

I tried building from source using mingw/msys but that had too many problems
so I gave up on that. I thought I might try building with MSVC 2010 since
it appears to be supported and I have that at work. There are a few problems
with this:
1. though I have looked in a few readme files, I don't see instructions for
installing what I have just built using MSVC. Where can I find the
instructions for installing after building with MSVC?

2. I have searched the project directory but I don't find python-config. Is
this some sort of optional thing that isn't built by default? I tried
searching this list and although I find a few questions about it, I don't
see an answer to where I can find it.

3. It seems that MSVC doesn't produce the .a library files needed for linking
into a mingw built program. Do I have to do that fun trick to create the
.a from the dll?

Damon Register
--
http://mail.python.org/mailman/listinfo/python-list


skippy.hammond at gmail

Jul 31, 2012, 8:49 PM

Post #2 of 5 (281 views)
Permalink
Re: missing python-config and building python on Windows [In reply to]

On 1/08/2012 10:48 AM, Damon Register wrote:
> I am attempting to build gtk and glade using mingw/msys. It seems that
> some
> of the packages require python. I installed 2.7.3 using the installer from
> python.org. That worked for some of the packages but now I am trying to do
> one that needs python-config which I don't find in the installation
> directory.
>
> I tried building from source using mingw/msys but that had too many
> problems
> so I gave up on that. I thought I might try building with MSVC 2010 since
> it appears to be supported and I have that at work. There are a few
> problems
> with this:
> 1. though I have looked in a few readme files, I don't see instructions for
> installing what I have just built using MSVC. Where can I find the
> instructions for installing after building with MSVC?

There is no such process. In general, you can just run directly from
the built tree.

> 2. I have searched the project directory but I don't find
> python-config. Is
> this some sort of optional thing that isn't built by default? I tried
> searching this list and although I find a few questions about it, I
> don't
> see an answer to where I can find it.

I'm afraid I don't know what python-config is. It appears it might be a
reflection of how Python was configured and build on *nix systems - if
that is the case then it is expected that one does not exist for Windows
(as it doesn't use the *nix build chain).

> 3. It seems that MSVC doesn't produce the .a library files needed for
> linking
> into a mingw built program. Do I have to do that fun trick to
> create the
> .a from the dll?

I'm surprised MSVC *can* build .a files for mingw - but AFAIK, even if
MSVC could do that, I believe Python makes no attempt to build with
support for linking into mingw programs.

Mark

--
http://mail.python.org/mailman/listinfo/python-list


damon.w.register at lmco

Aug 1, 2012, 4:47 AM

Post #3 of 5 (277 views)
Permalink
Re: EXTERNAL: Re: missing python-config and building python on Windows [In reply to]

On 7/31/2012 11:49 PM, Mark Hammond wrote:
> On 1/08/2012 10:48 AM, Damon Register wrote:
>> 1. though I have looked in a few readme files, I don't see instructions for
>> installing what I have just built using MSVC. Where can I find the
>> instructions for installing after building with MSVC?
>
> There is no such process. In general, you can just run directly from the built tree.
That is a bummer. That makes me more curious about how the Windows
installer was made and how all the pieces were gathered together.

> I'm afraid I don't know what python-config is. It appears it might be a reflection of how Python
> was configured and build on *nix systems - if that is the case then it is expected that one does not
> exist for Windows (as it doesn't use the *nix build chain).
which means, I guess, that mingw is barely supported if at all.
While it may be Windows, mingw/msys is a nice way to build many
programs that are unix oriented. I suppose that just for fun I
should try to build python on SuSE to see how it goes.

>> 3. It seems that MSVC doesn't produce the .a library files needed for
>> linking
>> into a mingw built program. Do I have to do that fun trick to
>> create the
>> .a from the dll?
>
> I'm surprised MSVC *can* build .a files for mingw - but AFAIK, even if MSVC could do that, I believe
> Python makes no attempt to build with support for linking into mingw programs.
I don't know that MSVC can do this. The only process of which I am aware is a
two step process using pexports and dlltool to generate the .a file from a dll.
One reason I was using the python.org installer is that it already had the
python27.a file. Now I am even more curious about what was used to build python
and create that installer.

The python.org installer provided all I needed for build most python dependent
apps with mingw until I ran into one that needed python-config. I suppose that
if python-config does what I suspect it does (produce cflags and ldflags as
does pkg-config) then perhaps I could just fake it by replacing use of
python-config with what the cflags and ldflags should be for where I have
python.

Damon Register

--
http://mail.python.org/mailman/listinfo/python-list


ramit.prasad at jpmorgan

Aug 1, 2012, 8:31 AM

Post #4 of 5 (279 views)
Permalink
RE: EXTERNAL: Re: missing python-config and building python on Windows [In reply to]

> On 7/31/2012 11:49 PM, Mark Hammond wrote:
> > On 1/08/2012 10:48 AM, Damon Register wrote:
> >> 1. though I have looked in a few readme files, I don't see instructions for
> >> installing what I have just built using MSVC. Where can I find the
> >> instructions for installing after building with MSVC?
> >
> > There is no such process. In general, you can just run directly from the
> built tree.
> That is a bummer. That makes me more curious about how the Windows
> installer was made and how all the pieces were gathered together.
>
> > I'm afraid I don't know what python-config is. It appears it might be a
> reflection of how Python
> > was configured and build on *nix systems - if that is the case then it is
> expected that one does not
> > exist for Windows (as it doesn't use the *nix build chain).
> which means, I guess, that mingw is barely supported if at all.
> While it may be Windows, mingw/msys is a nice way to build many
> programs that are unix oriented. I suppose that just for fun I
> should try to build python on SuSE to see how it goes.
>
> >> 3. It seems that MSVC doesn't produce the .a library files needed for
> >> linking
> >> into a mingw built program. Do I have to do that fun trick to
> >> create the
> >> .a from the dll?
> >
> > I'm surprised MSVC *can* build .a files for mingw - but AFAIK, even if MSVC
> could do that, I believe
> > Python makes no attempt to build with support for linking into mingw
> programs.
> I don't know that MSVC can do this. The only process of which I am aware is a
> two step process using pexports and dlltool to generate the .a file from a
> dll.
> One reason I was using the python.org installer is that it already had the
> python27.a file. Now I am even more curious about what was used to build
> python
> and create that installer.
>
> The python.org installer provided all I needed for build most python dependent
> apps with mingw until I ran into one that needed python-config. I suppose
> that
> if python-config does what I suspect it does (produce cflags and ldflags as
> does pkg-config) then perhaps I could just fake it by replacing use of
> python-config with what the cflags and ldflags should be for where I have
> python.

I have no knowledge about building Python but does this help?
http://wiki.python.org/moin/Building%20Python%20with%20the%20free%20MS%20C%20Toolkit

Ramit

This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.
--
http://mail.python.org/mailman/listinfo/python-list


tjreedy at udel

Aug 1, 2012, 10:09 AM

Post #5 of 5 (274 views)
Permalink
Re: EXTERNAL: Re: missing python-config and building python on Windows [In reply to]

On 8/1/2012 7:47 AM, Damon Register wrote:
> On 7/31/2012 11:49 PM, Mark Hammond wrote:
>> On 1/08/2012 10:48 AM, Damon Register wrote:
>>> 1. though I have looked in a few readme files, I don't see
>>> instructions for
>>> installing what I have just built using MSVC. Where can I find the
>>> instructions for installing after building with MSVC?
>>
>> There is no such process. In general, you can just run directly from
>> the built tree.
> That is a bummer. That makes me more curious about how the Windows
> installer was made and how all the pieces were gathered together.

All I know is that the Windows installer is a .msi file created by a
script that uses msilib. I don't know whether that script is in the
repository.

--
Terry Jan Reedy



--
http://mail.python.org/mailman/listinfo/python-list

Python python RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.