summaryrefslogtreecommitdiffhomepage
path: root/src/Xmobar/App/Compile.hs
AgeCommit message (Collapse)Author
2024-03-30Fix waitForProcess errors when configuration is recompiledUlrik de Muelenaere
Previously, xmobar would ignore SIGCHLD, but only when the configuration is recompiled. This means child processes would not leave zombies, so that waiting for them to exit (either directly by calling waitForProcess, or indirectly through another function from System.Process, like system or readProcessWithExitCode) would produce an error. This breaks the Alsa, Com (#657) and NotmuchMail plugins, as well as the <action> tag (#687) and low battery action (#688). As far as I can tell, bracketing the recompilation in uninstallSignalHandlers and installSignalHandlers was inherited from xmonad. In xmonad, SIGPIPE and SIGCHLD are always ignored (installSignalHandlers is called at the start of xmonad and launch), so the bracket is necessary to be able to wait for the compiler or build script to exit. Since xmobar does not otherwise ignore the signals, it is not necessary to change signal handlers at all during recompilation. Removing it leaves the default action for SIGCHLD, which fixes the issues described above. Fixes #657, #687 and #688.
2024-01-31Enable use of shared librariesVekhir
Haskell libraries can be linked statically or dynamically. Either way, all packages must be linked the same way. This means that if all dependencies of `xmobar` are shared libraries, then `xmobar` itself must be built using dynamic linking. Therefore, to compile the individual `xmobar` executables, add the `-dynamic` flag to signal that they are built with shared libraries. This flag is put behind an #ifdef to easily configure static vs dynamic linking. To use shared libraries, define SHARED_LIBRARIES
2021-03-18Fix typo `DRTSOPTS` -> `RTSOPTS`Claudio Bley
The cpp option `-DRTSOPTS` results in `RTSOPTS` being defined.
2019-09-06Write error log to data dir, not conf dirChuck
Write xmobar.errors to XMOBAR_DATA_DIR, not XMOBAR_CONFIG_DIR. This allows XMOBAR_CONFIG_DIR to be read-only. This brings xmobar into alignment with how xmonad manages its analogous directories (before this change, a read-only DATA dir worked with xmonad but not with xmobar).
2018-12-08Compiling only .[l]hs[c] filesjao
Should take care of issue #371
2018-12-01Propagating RTS compilation flags to recompilejao
2018-11-30Self-compilation a la xmonadjao
2018-11-26Lintingjao
2018-11-26Compilation functions lifted from xmonadjao