libjson-c: fix host-build
[openwrt/staging/wigyori.git] / package / libs / toolchain / Makefile
index cf4a20905421be13558f65c5fafd08ae355ff488..febc7c2dbcae69c9842ffb3c2546786c1ba125d4 100644 (file)
@@ -83,7 +83,7 @@ endef
 
 define Package/libssp
 $(call Package/gcc/Default)
-  DEPENDS+=@SSP_SUPPORT
+  DEPENDS+=@GCC_LIBSSP
   TITLE:=GCC support library
 endef
 
@@ -164,7 +164,7 @@ define Package/libc/config
                string
                prompt "libc shared library files (use wildcards)"
                depends on EXTERNAL_TOOLCHAIN && PACKAGE_libc
-               default "./lib/ld{*.so*,-linux*.so.*} ./lib/lib{anl,c,cidn,crypt,dl,m,nsl,nss_dns,nss_files,resolv,util}{-*.so,.so.*}"
+               default "./lib/ld{*.so*,-linux*.so.*} ./lib/lib{anl,c,cidn,crypt,dl,m,nsl,nss_dns,nss_files,resolv,util}{-*.so,.so.*,.so}"
 
        endmenu
 endef
@@ -202,6 +202,26 @@ $(call Package/libc/Default)
   TITLE:=POSIX thread library debugging support
 endef
 
+define Package/libthread-db/config
+       menu "Configuration"
+       depends on EXTERNAL_TOOLCHAIN && PACKAGE_libthread-db
+
+       config LIBTHREAD_DB_ROOT_DIR
+               string
+               prompt "POSIX thread debugging shared library base directory"
+               depends on EXTERNAL_TOOLCHAIN && PACKAGE_libthread-db
+               default TOOLCHAIN_ROOT  if !NATIVE_TOOLCHAIN
+               default "/"  if NATIVE_TOOLCHAIN
+
+       config LIBTHREAD_DB_FILE_SPEC
+               string
+               prompt "POSIX thread debugging shared library files (use wildcards)"
+               depends on EXTERNAL_TOOLCHAIN && PACKAGE_libthread-db
+               default "./lib/libthread_db{-*.so,.so.*}"
+
+       endmenu
+endef
+
 define Package/librt
 $(call Package/libc/Default)
   TITLE:=POSIX.1b RealTime extension library
@@ -255,6 +275,32 @@ define Package/libgfortran/config
        endmenu
 endef
 
+define Package/libgomp
+$(call Package/gcc/Default)
+  TITLE:=OpenMP support library
+endef
+
+define Package/libgomp/config
+       menu "Configuration"
+               depends on EXTERNAL_TOOLCHAIN && PACKAGE_libgomp
+
+       config LIBGOMP_ROOT_DIR
+               string
+               prompt "libgomp shared library base directory"
+               depends on EXTERNAL_TOOLCHAIN && PACKAGE_libgomp
+               default TOOLCHAIN_ROOT  if !NATIVE_TOOLCHAIN
+               default "/"  if NATIVE_TOOLCHAIN
+
+       config LIBGOMP_FILE_SPEC
+               string
+               prompt "libgomp shared library files (use wildcards)"
+               depends on EXTERNAL_TOOLCHAIN && PACKAGE_libgomp
+               default "./lib/libgomp.so*"
+
+       endmenu
+endef
+
+
 define Package/ldd
 $(call Package/libc/Default)
   DEPENDS:=@!USE_MUSL
@@ -517,6 +563,14 @@ else
        exit 0
   endef
 
+  define Package/libthread-db/install
+       for file in $(call qstrip,$(CONFIG_LIBTHREAD_DB_FILE_SPEC)); do \
+               $(INSTALL_DIR) $(1)/lib ; \
+               $(CP) $(call qstrip,$(CONFIG_LIBTHREAD_DB_ROOT_DIR))/$$$$file $(1)/lib/ ; \
+       done ; \
+       exit 0
+  endef
+
   define Package/librt/install
        for file in $(call qstrip,$(CONFIG_LIBRT_FILE_SPEC)); do \
                $(INSTALL_DIR) $(1)/lib ; \
@@ -533,6 +587,14 @@ else
        exit 0
   endef
 
+  define Package/libgomp/install
+       for file in $(call qstrip,$(CONFIG_LIBGOMP_FILE_SPEC)); do \
+               $(INSTALL_DIR) $(1)/lib ; \
+               $(CP) $(call qstrip,$(CONFIG_LIBGOMP_ROOT_DIR))/$$$$file $(1)/lib/ ; \
+       done ; \
+       exit 0
+  endef
+
   define Package/ldd/install
        for file in $(call qstrip,$(CONFIG_LDD_FILE_SPEC)); do \
                dir=`dirname $$$$file` ; \
@@ -562,5 +624,6 @@ $(eval $(call BuildPackage,libpthread))
 $(eval $(call BuildPackage,libthread-db))
 $(eval $(call BuildPackage,librt))
 $(eval $(call BuildPackage,libgfortran))
+$(eval $(call BuildPackage,libgomp))
 $(eval $(call BuildPackage,ldd))
 $(eval $(call BuildPackage,ldconfig))