usepackage 'optional' options

Ulrike Fischer news3 at nililand.de
Mon Mar 23 11:39:16 CET 2020


Am Sun, 22 Mar 2020 12:18:43 -0700 schrieb Ovi Chitayat:

> Hi,
> I have a package that requires an option under windows 10. However, when
> job is processed under MacOS Catalina, the package would not perform unless
> that option is removed.
> Is there a way to make the option conditional upon the computing
> platform currently running?
> 
> The specific package is gnuplottex, under windows 10, gnuplot will not be
> called unless \usepackage[miktex]{gnuplottex}. This will not work under
> Catalina that likes the generic \usepackage{gnuplottex}.
> I tried to contact the maintainer (Lars Kotthoff) on record but this proved
> tricky.

The test in the package is actually misnamed. The main point is not
if miktex is used but if you are on windows or linux. 

There is a ifplatform package which allow to test for windows and
macos. It should work in your case. 


-- 
Ulrike Fischer 
http://www.troubleshooting-tex.de/



More information about the texhax mailing list.