summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2011-03-13 22:10:57 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2011-03-13 22:10:57 +0100
commiteaac9112e564688cd15d993dcb2306a597cb4f39 (patch)
tree7a31ad9fc7bc40a98fb79cf058c880ffd43193f4
parentf5785bd186eac9b4ac928477bb43478447f52985 (diff)
add devel subpackage with linker scripts
-rw-r--r--package/libpthread/Makefile17
-rw-r--r--package/libpthread/files/libpthread.so.x865
-rw-r--r--package/libpthread/files/libpthread.so.x86_645
3 files changed, 25 insertions, 2 deletions
diff --git a/package/libpthread/Makefile b/package/libpthread/Makefile
index feda89f6a..169db676a 100644
--- a/package/libpthread/Makefile
+++ b/package/libpthread/Makefile
@@ -12,6 +12,10 @@ endif
ifeq ($(ADK_TARGET_LIB_UCLIBC),y)
include ${TOPDIR}/toolchain/uClibc/Makefile.inc
endif
+ifeq ($(ADK_NATIVE),y)
+PKG_VERSION:= 1.0
+PKG_RELEASE:= 1
+endif
PKG_NAME:= libpthread
PKG_DESCR:= POSIX threading library
@@ -19,6 +23,8 @@ PKG_SECTION:= libs
NO_DISTFILES:= 1
+PKG_SUBPKGS:= LIBPTHREAD LIBPTHREAD_DEV
+
ifeq ($(ADK_STATIC),y)
PKG_OPTS:= libonly
endif
@@ -26,16 +32,23 @@ endif
include ${TOPDIR}/mk/package.mk
$(eval $(call PKG_template,LIBPTHREAD,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
+$(eval $(call PKG_template,LIBPTHREAD_DEV,${PKG_NAME}-dev,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
CONFIG_STYLE:= manual
BUILD_STYLE:= manual
INSTALL_STYLE:= manual
-do-install:
+libpthread-install:
ifeq ($(ADK_NATIVE),)
${INSTALL_DIR} ${IDIR_LIBPTHREAD}/lib
${CP} ${STAGING_TARGET_DIR}/lib/libpthread*.so* ${IDIR_LIBPTHREAD}/lib
- cd $(IDIR_LIBPTHREAD)/lib && ln -sf libpthread.so.0 libpthread.so
+endif
+
+libpthread-dev-install:
+ifeq ($(ADK_NATIVE),)
+ ${INSTALL_DIR} ${IDIR_LIBPTHREAD}/usr/lib
+ ${CP} ./files/libpthread.so.$(ARCH) ${IDIR_LIBPTHREAD}/usr/lib/libpthread.so
+ ${CP} ${STAGING_TARGET_DIR}/usr/lib/libpthread_nonshared.a ${IDIR_LIBPTHREAD}/usr/lib
endif
include ${TOPDIR}/mk/pkg-bottom.mk
diff --git a/package/libpthread/files/libpthread.so.x86 b/package/libpthread/files/libpthread.so.x86
new file mode 100644
index 000000000..e7555c820
--- /dev/null
+++ b/package/libpthread/files/libpthread.so.x86
@@ -0,0 +1,5 @@
+/* GNU ld script
+ Use the shared library, but some functions are only in
+ the static library, so try that secondarily. */
+OUTPUT_FORMAT(elf32-i386)
+GROUP ( /lib/libpthread.so.0 /usr/lib/libpthread_nonshared.a )
diff --git a/package/libpthread/files/libpthread.so.x86_64 b/package/libpthread/files/libpthread.so.x86_64
new file mode 100644
index 000000000..b0e31f904
--- /dev/null
+++ b/package/libpthread/files/libpthread.so.x86_64
@@ -0,0 +1,5 @@
+/* GNU ld script
+ Use the shared library, but some functions are only in
+ the static library, so try that secondarily. */
+OUTPUT_FORMAT(elf64-x86-64)
+GROUP ( /lib/libpthread.so.0 /usr/lib/libpthread_nonshared.a )