davidjoffe / dave_gnukem

Dave Gnukem is a cross-platform 2D scrolling platform shooter inspired by Duke Nukem 1
GNU General Public License v2.0
75 stars 22 forks source link

BSD Makefile deletion #202

Closed matteobin closed 9 months ago

matteobin commented 10 months ago

Hi David, I tried to reach you by email, but you've never answered me. Have my emails been sent to your spam folder?

Here's your favourite GNU/Linux and Debian friend writing a Makefile suggestion for you. I wanted to synchronise the BSD Makefile with the new content of the main one, when I realised that they would differ for just ONE line. The following:

-OBJ = $(shell find src -iname '*.cpp' -type f | sed 's/\.cpp$$/.o/' | sort)
+OBJ != find src -iname '*.cpp' -type f | sed 's/\.cpp$$/.o/' | sort

As convenient as it is, I don't think that dynamically defining the OBJ variable is worth having two separate Makefiles. Besides, getting a list of all the source files is just a matter of running the same script that now populates the OBJ variable.

davidjoffe commented 10 months ago

Hi, thanks, I just want to maybe try test this in a BSD VM when I get a chance, thanks! Bit busy right now ... will come back to this

davidjoffe commented 9 months ago

I've not specifically been able to test on BSD yet but I think if any issues come up we can deal with them if/as they come up and better to move away from those old hardcoded lists of .o files, I agree it's much better to get dynamically