CharPyLS
CharPyLS copied to clipboard
MAINT allow to set environment variable at install
This is not practical to hard code flag_MSCV
since that one can need to install the package from pip without editing the setup.py
. In this regard, I did a small hack to read an environment variable to turn ON/OFF the flag for the install.
@glemaitre I updated the setup.py file to check the system platform type before setting any specific compiler or linker options. This is prefered over setting/reading environment variables.
What would happen if you use mingwin in windows? The flag seems to be for MSCV so I was unsure that checking the os would work under Windows with another compiler than MSCV
@glemaitre yikes I cannot believe how difficult this became! I don't know the 'best' way to set these options that also allows for MINGW, and I just spent half my morning unsuccessfully trying to figure it out. For now I've removed the platform-specific compiler arguments.
I thought to pass --install-option="args" when installing with pip. However it is not so much documented and I wanted to have a quick fix for a CI. I don't know what you think about passing option at install?
Passing options at pip CLI would be perfect!