MVoz / libmpsse

Automatically exported from code.google.com/p/libmpsse
0 stars 0 forks source link

Unable to build out-of-source #36

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I'm trying to build libmpsse trunk (r202) out-of-source. So something like:

cd somedirectory
../../../libmpsse/src/configure --prefix=/local_install_directory 
CFLAGS="-I/myotherrootfs" LDFLAGS="-L/myotherrootfs/lib64"

Configure succeeds and generates a makefile but the file names are all relative 
to the original source directory.

This looks to come directly from Makefile.in (I'm not super familiar with 
autotools at this point):

mpsse.o: support.o
    $(CC) $(CFLAGS) $(LDFLAGS) -DLIBFTDI1=$(LIBFTDI1) -c mpsse.c

I've started to modify the Makefile.in to use ${srcdir) etc but I'm wondering 
if you would be opposed to switching to cmake. Libftdi uses it for their build 
system and I suspect it would make it much easier to handle things like this. 
It would also make it easier to detect libftdi, there is a helpful cmake script 
that libftdi installs that will retrieve the libraries and include paths.

I could provide the CMakeLists.txt file if that would be helpful as I need to 
integrate this into our build system and we try hard to perform out-of-source 
builds.

chmorgan@gmail.com if you want to get ahold of me.

Original issue reported on code.google.com by chmor...@gmail.com on 14 Oct 2013 at 1:14

GoogleCodeExporter commented 9 years ago
I would like Cmake too! ;)   ... along with git source code control... But I'm 
probably asking too much.

Original comment by robokni...@gmail.com on 29 Nov 2013 at 4:08

GoogleCodeExporter commented 9 years ago
I've actually completed the switch on my github account. Check it out here:

https://github.com/chmorgan/libmpsse

And let me know how it works for you. Patches welcome.

Chris

Original comment by chmor...@gmail.com on 29 Nov 2013 at 10:50

GoogleCodeExporter commented 9 years ago
Oh, and its on the cmake_wip branch btw. I haven't merged that branch back into 
master yet.

Original comment by chmor...@gmail.com on 30 Nov 2013 at 6:56

GoogleCodeExporter commented 9 years ago
I've updated this cmake_wip branch to include a find_packages() script for 
libmpsse, along with an example of how to find libmpsse from your 
CMakeLists.txt file.

Original comment by chmor...@gmail.com on 18 Dec 2013 at 12:15