opensslconf.h not found

I'm trying to build znort987's parser, and have executed sudo apt-get libssl-dev. I can see all sorts of ssl related header files in /usr/include/openssl but opensslconf.h is missing from the openssl folder and the make command raises the error:

 make: *** No rule to make target `/usr/include/openssl/opensslconf.h', needed by `.objs/rmd160.o'.  Stop.

I'm using Ubuntu 14.04 on a 32 bit AMD laptop.

Update: I executed the following to cleanout my installation:

sudo apt-get remove libssl-dev build-essential g++-4.4 libboost-all-dev libsparsehash-dev git-core perl
sudo apt-get install libssl-dev build-essential g++-4.4 libboost-all-dev libsparsehash-dev git-core perl
git clone git://github.com/znort987/blockparser.git
cd blockparser
make

Now I get:

/usr/include/openssl/e_os2.h:56:33: fatal error: openssl/opensslconf.h: No such file or directory


If you're building on a 64-system and you're targeting 32-bit, the following command fixed this issue for me:

sudo apt-get install libssl-dev:i386

This stuff seems to have happened a long time ago (specifically, 2013-05-20 16:56:06 UTC). I ran into a weird problem that looked very much like the OP, but it turned out to be a problem with swig failing to attach the right set of includes when compiling. I ended up hunting through the source just to make sure it wasn't a ubuntu package problem, but it didn't seem to be an issue with ubuntu.

Looking more carefully into this, the openssl package shifted opensslconf.h into a multiarch-aware directory structure. Here's the detailed commit: http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/utopic/openssl/utopic-updates/revision/11.1.42 and if you want to see how I came up with that revision, I followed the annotated revisions of the debian rules which was a surprisingly efficient way to figure out what happened: http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/utopic/openssl/utopic-updates/annotate/head:/debian/rules.

And the committer, Kurt Roeckx, writes in the Changelog:

  • Move to /usr/include/$(DEB_HOST_MULTIARCH), and mark libssl-dev Multi-Arch: same.

To be fair, I wish the opensslconf.h was, at least, symlinked into the /usr/include/openssl folder with the rest of the logically related headers. But that's not a bug, that's just my opinion. To the folks that run into this problem like I did, it just takes a bit of sniffing out missing includes to keep things humming along.

And to the OP, it's quite a lot later now, but I just gave your exact set of steps a run through on a 14.04 LTS x64 box and didn't run into the problem you were having. Perhaps the problem was simply solved over time. Hope some of this helps.


have executed sudo apt-get libssl-dev. I can see all sorts of ssl related header files in /usr/include/openssl but opensslconf.h is missing from the openssl folder and the make command raises the error ...

It sounds like the package is defective.

<openssl/opensslconf.h> is created by OpenSSL's Configure command. It should be included with the distro files. The earliest mention I could find was OpenSSL's CHANGELOG at version 0.9.2.

File a bug report at https://bugs.launchpad.net/ubuntu/+filebug/?no-redirect.