From: claurita <claudio.laurita@integrazionetotale.it>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v7] canfestival: new package
Date: Tue, 23 Sep 2014 10:06:40 -0700 (PDT) [thread overview]
Message-ID: <1411492000260-80004.post@n4.nabble.com> (raw)
In-Reply-To: <1404048539-14788-1-git-send-email-s.martin49@gmail.com>
I'd like to propose a little patch to add pkg-config support.
It's only a draft proposal, even if I'm using it. I hope it could be useful.
Claudio
diff --git a/canfestival.pc.in b/canfestival.pc.in
new file mode 100644
index 0000000..08ecbe1
--- /dev/null
+++ b/canfestival.pc.in
@@ -0,0 +1,12 @@
+PREFIX = SUB_PREFIX
+TARGET = SUB_TARGET
+
+prefix=${DESTDIR}${PREFIX}
+libdir=${prefix}/lib
+includedir=${prefix}/include/canfestival
+
+Name: Canfestival
+Description: Canfestival CANOpen library
+Version: 1
+Libs: -L${libdir} -lcanfestival -lcanfestival_${TARGET} -lrt -ldl -lpthread
+Cflags: -I${includedir}
diff --git a/configure b/configure
index b63b276..6d909d6 100755
--- a/configure
+++ b/configure
@@ -825,6 +825,7 @@ elif [ "$SUB_TARGET" = "unix" -a "$SUB_TIMERS_DRIVER" =
"kernel_xeno" ]; then
elif [ "$SUB_TARGET" = "unix" ]; then
MAKEFILES=$MAKEFILES\
+\ canfestival.pc.in\
\ examples/CANOpenShell/Makefile.in\
\ examples/TestMasterSlave/Makefile.in\
\ examples/TestMasterSlaveLSS/Makefile.in\
diff --git a/src/Makefile.in b/src/Makefile.in
index e709f4f..8bee33d 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -132,9 +132,10 @@ $(TARGET)_%.o: %.c
$(CC) $(CFLAGS) $(PROG_CFLAGS) ${PROGDEFINES} $(INCLUDES) -o $@ -c $<
install: libcanfestival.a
- mkdir -p $(DESTDIR)$(PREFIX)/lib/
+ mkdir -p $(DESTDIR)$(PREFIX)/lib/pkgconfig/
mkdir -p $(DESTDIR)$(PREFIX)/include/canfestival
cp libcanfestival.a $(DESTDIR)$(PREFIX)/lib/
+ cp ../canfestival.pc $(DESTDIR)$(PREFIX)/lib/pkgconfig/
cp ../include/*.h $(DESTDIR)$(PREFIX)/include/canfestival
uninstall:
--
View this message in context: http://buildroot-busybox.2317881.n4.nabble.com/PATCH-v7-canfestival-new-package-tp73727p80004.html
Sent from the Buildroot (busybox) mailing list archive@Nabble.com.
next prev parent reply other threads:[~2014-09-23 17:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-29 13:28 [Buildroot] [PATCH v7] canfestival: new package Samuel Martin
2014-09-23 17:06 ` claurita [this message]
2014-09-23 17:52 ` Thomas Petazzoni
2014-09-23 20:28 ` claurita
2014-09-23 21:28 ` Samuel Martin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1411492000260-80004.post@n4.nabble.com \
--to=claudio.laurita@integrazionetotale.it \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox