glava
glava copied to clipboard
OSX Support
I had installed this on Ubuntu, and I would like to have a visualizer that worked for Mac. everything went well until I got to sudo make install. Make output this:
gingkathfox$ sudo make install
readlink: illegal option -- m
usage: readlink [-n] [file ...]
readlink: illegal option -- m
usage: readlink [-n] [file ...]
readlink: illegal option -- m
usage: readlink [-n] [file ...]
install -Dm755 glava
install: illegal option -- D
usage: install [-bCcpSsv] [-B suffix] [-f flags] [-g group] [-m mode]
[-o owner] file1 file2
install [-bCcpSsv] [-B suffix] [-f flags] [-g group] [-m mode]
[-o owner] file1 ... fileN directory
install -d [-v] [-g group] [-m mode] [-o owner] directory ...
make: *** [install] Error 64
Any idea why this happened?
I know this isn't particularly clear because I have paved the way for OSX support, but the requirements state:
Requirements:
- [...]
- Linux or BSD
There are a number of things that will not work on OSX at the moment, including the Makefile. Additionally, you need to use an audio backend available on OSX (fifo should work out of the box and pulseaudio will need support [brew install pulseaudio]), GLFW window creation, and X11 support with various extensions (XComposite, XShape, XShm) -- I am not sure if XQuartz facilitates this.
It is possible to remove the hard requirements on X11 completely and the code has been written in a way to facilitate this. This would make the GLFW backend to be restricted to normal windows and platform independent.
I do not own a Mac and never plan to purchase one. I have simply kept in mind OSX support in the future in the event of someone willing to take on development. While cross-compiling is possible with some pain, virtualization is the required solution, ~~and I'm not going there~~. If you want more detailed reasoning for this, I'm happy to discuss it.
If you have Discord, that would be great so we could discuss it.
I like how you paved the way for a MacOS port, maybe ill get a friend to teach me some C so I can port it.
I don't think there's much to discuss. Write a working prototype, create PR, get reviewed, ta-da.
True XD Also, I think XQuartz might actually have X11.
I am re-visiting OSX support after I am complete with glava-config (nearly complete), glava-obs, and some minor module changes. I dug into what was required and it turns out it's not out of reach:
-
AGL over GLX avoids the need for XQuartz (which isn't even bundled with OSX anymore and is generally regarded as unmaintained garbage), and is accessible in pure C so I don't need an Objective C wrapper for the windowing implementation.
- Initial XQuartz support, has already been added in 859bfb0 regardless because it can just use the GLX backend. I do not aim to expand on this, though, and will have this backend disabled at compile time unless someone expresses the need for this.
-
Most of GLava's X11-specific code is organized in either
xwin.corglx_wcb.c. The latter is already behind an interface. -
OSX has largely moved over to Clang, and I have added support for building with Clang in 5637925, so this avoids having to use Apple's GCC fork. This was a bit of a rollercoaster since I had to do some macro magic to maintain my use of GNUC nested function via Clang block types.
- I had a couple of requests to do so over the past year on Linux as well, so it was worth tackling alone.
-
An audio backend can be done with PortAudio to massively simplify the recording process, which has the added bonus of being crossplatform.
Please note this is not a priority for me and likely will not be fully functional when I tag v2.0, as I'm doing this purely as an exercise in porting software.
OSX has largely moved over to Clang,
True, better to use Homebrew GCC tho (ive had issues with Clang and building apps)
@GingkathFox that's because some applications don't support building under clang. BSD users are moving to Clang (and generally prefer it) and Apple has largely already done the same -- who have dropped support entirely for their ancient fork.
Be patient though, GLava isn't doing anything for OSX until everything else on my checklist for 2.0 is done.
ok, cool :D