Using Makefiles in Python projects

Barry Scott barry at barrys-emacs.org
Sun Nov 10 08:37:06 EST 2019



> On 10 Nov 2019, at 00:09, Skip Montanaro <skip.montanaro at gmail.com> wrote:
> 
> (Sorry, not 100% sure of the credit for this quote, Vitaly, perhaps?)
> 
>>>> If your software runs on Windows, of you think it might run on Windows
>>>> in the future, maybe consider writing simple Python scripts for
>>>> platform-independent tasks rather than makefiles and shell scripts.
> 
> Maybe try SCons or CMake for cross-platform functionality?
> 
> Chris:
> 
>>> Are you assuming that every Windows system has Python, but that you
>>> can't get make or bash? Because neither half of that is true. I've
>>> happily used makefiles on Windows, and these days, bash is as easy to
>>> get hold of as Python is.
> 
> Thomas:
> 
>> That's why I say "a bit of a hassle". You can get a MSYS set up (whether
>> from Git for Windows or otherwise). You can get it to play nice with the
>> right Python installation and the Python scripts you presumably want to
>> call from the Makefile. But all of that is a bit of a hassle.
> 
> I thought recent versions of Win10 had a full Ubuntu subsystem. Before
> that, doesn't something like Cygwin still exist/work?

If you are working on native Windows apps then cygwin or WSL will not help you
as they hide the Windows world from you.

Personally I write .CMD files for the windows stuff I need to mirror the
bash .sh scripts I use. They tend to bootstrap up python build tools I
use.

Barry

> 
> Disclaimer: I am not a Windows person, and managed to avoid it for my
> entire career.
> 
> Skip
> -- 
> https://mail.python.org/mailman/listinfo/python-list
> 



More information about the Python-list mailing list