Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use autoconf to create Makefile #9

Closed
lattera opened this issue Mar 7, 2016 · 6 comments
Closed

Use autoconf to create Makefile #9

lattera opened this issue Mar 7, 2016 · 6 comments

Comments

@lattera
Copy link

lattera commented Mar 7, 2016

I ported the Makefile by hand to use BSD Makefile syntax so that I could add it to the HardenedBSD ports tree. Ideally, the Makefile shouldn't have to be hand-edited. As much as I dislike autoconf, it might be of use here. In the BSDs (or at least in FreeBSD and HardenedBSD), jo needs to link with the math library (-lm). I'm going to guess you're using a Linux distro that probably doesn't need that. Using autoconf would allow you to detect whether you need to link with any libraries and it would auto-generate the Makefile based on a template (the Makefile.am file). I'd supply a patch with this issue myself, but my time is very limited.

To take a look at what's different between my Makefile and yours, take a look at: master...lattera:master (ignore the obj directory I created)

@jpmens
Copy link
Owner

jpmens commented Mar 7, 2016 via email

@jpmens
Copy link
Owner

jpmens commented Mar 7, 2016 via email

@lattera
Copy link
Author

lattera commented Mar 7, 2016

Cool! I've done a little bit of autoconf work, but it's been over a year, so I'd be a little on the rusty side. I reorganized ClamAV's autoconf scripts to be a bit more sane, you might wanna take a look at that (link below). ClamAV's autoconf scripts are way overkill for such a simple app like jo, but it might give you a good place to start from.

It looks like -lm is needed on 11.0-CURRENT. Jo wouldn't build without it.

https://github.com/vrtadmin/clamav-devel/blob/master/configure.ac

@jpmens
Copy link
Owner

jpmens commented Mar 8, 2016

I've pushed an experimental branch autot with autotools support. Could you verify that it does for you, what it ought to do? I've tested this a bit on several platforms and "it works on my machines(™)" ;-)

As soon as you give the OK, I'll merge to master and make a release.

@jpmens
Copy link
Owner

jpmens commented Mar 8, 2016

I've merged to master.

@jpmens
Copy link
Owner

jpmens commented Mar 8, 2016

So, I hope this is the last time I bother you :) I've released version 0.4.

@jpmens jpmens closed this as completed Mar 9, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants