[sage-devel] Re: Workaround for missing link to MacTex for MacOS Sage app
See https://trac.sagemath.org/ticket/4 Weirdly, I have precisely this situation of having upgraded to El Capitan and not having upgraded my Sage, but LaTeX works fine, contra "If you had an old version of TeX Live (2014 or earlier) and then upgraded your operating system to Sierra, TeX will no longer work." but I haven't tried using the Mac app with it, as I use a locally compiled Sage for SageTeX. On Friday, January 20, 2017 at 9:17:44 PM UTC-5, Michael Frey wrote: > > Yes, it appears to have the path hard coded somewhere. My global path does > contain /Library/TeX/texbin which appears to come from /etc/paths.d/TeX. > > I originally modified the > /Applications/SageMath-7.5.1.app/Contents/Resources/start-sage.sh > file. I then modified the src/mac-app/start-sage.sh file and rebuilt the > Sage app dmg to test that this would install without problems. > > The only references I can find in the sage source tree are in several > copies of same file, loading-page.html: > > adding os.environ["PATH"]+=":/usr/texbin:/usr/local/bin" to > $HOME/.sage/init.sage > > > My system does not have a ~/.sage/init.sage file. > That's because not everyone does. IF you had an init.sage, one would want to do that, I guess. -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Workaround for missing link to MacTex for MacOS Sage app
Yes, it appears to have the path hard coded somewhere. My global path does contain /Library/TeX/texbin which appears to come from /etc/paths.d/TeX. I originally modified the /Applications/SageMath-7.5.1.app/Contents/Resources/start-sage.sh file. I then modified the src/mac-app/start-sage.sh file and rebuilt the Sage app dmg to test that this would install without problems. The only references I can find in the sage source tree are in several copies of same file, loading-page.html: adding os.environ["PATH"]+=":/usr/texbin:/usr/local/bin" to $HOME/.sage/init.sage My system does not have a ~/.sage/init.sage file. Mike On Thursday, January 19, 2017 at 11:12:22 PM UTC-5, Michael Frey wrote: > > I found that when trying to access LATeX (MacTeX) calls in a Sage notebook > via MatPlotLib or directly Sage would report that it could not find some > TeX function. It appears that the PATH variable being used by the Sage app > is pointing to /usr/texbin, not /Library/TeX/texbin. As a workaround I > modified src/mac-app/start-sage.sh and added: > > if test -d /Library/TeX/texbin > > then > > export PATH=$PATH:/Library/TeX/texbin > > fi > > > After rebuilding the Sage app dmg, Sage works as expected when accessing > TeX calls. > > > There may be a better way, but I could not find one searching through the > Sage source. > > > I am not sure how proceed with getting this corrected so users do not have > the manually edit the start-sage.sh file. > > > Regards, > > > Mike > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Workaround for missing link to MacTex for MacOS Sage app
yes, I agree this should be updated, according to https://www.tug.org/mactex/sierra.html I cc to the primary developer of sage.app. On Friday, January 20, 2017 at 4:12:22 AM UTC, Michael Frey wrote: > > I found that when trying to access LATeX (MacTeX) calls in a Sage notebook > via MatPlotLib or directly Sage would report that it could not find some > TeX function. It appears that the PATH variable being used by the Sage app > is pointing to /usr/texbin, not /Library/TeX/texbin. As a workaround I > modified src/mac-app/start-sage.sh and added: > > if test -d /Library/TeX/texbin > > then > > export PATH=$PATH:/Library/TeX/texbin > > fi > > > After rebuilding the Sage app dmg, Sage works as expected when accessing > TeX calls. > strange that you needed to rebuild - are you saying that sage.app does hardcore path, rather than getting it from the environment? > > There may be a better way, but I could not find one searching through the > Sage source. > > > I am not sure how proceed with getting this corrected so users do not have > the manually edit the start-sage.sh file. > > > Regards, > > > Mike > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.