From 51551bb3763497122f88db3c996946c0d96ac62e Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Wed, 25 Jan 2012 13:19:32 +0000 Subject: main/yajl: moved frrom testing --- main/yajl/APKBUILD | 56 +++++++++++++++++++++++++++++++++++++++++++++++++ main/yajl/libm.patch | 45 +++++++++++++++++++++++++++++++++++++++ testing/yajl/APKBUILD | 56 ------------------------------------------------- testing/yajl/libm.patch | 45 --------------------------------------- 4 files changed, 101 insertions(+), 101 deletions(-) create mode 100644 main/yajl/APKBUILD create mode 100644 main/yajl/libm.patch delete mode 100644 testing/yajl/APKBUILD delete mode 100644 testing/yajl/libm.patch diff --git a/main/yajl/APKBUILD b/main/yajl/APKBUILD new file mode 100644 index 000000000..7a0d6e8ac --- /dev/null +++ b/main/yajl/APKBUILD @@ -0,0 +1,56 @@ +# Maintainer: Natanael Copa +pkgname=yajl +pkgver=2.0.3 +pkgrel=0 +pkgdesc="Yet Another JSON Library (YAJL)" +url="http://lloyd.github.com/yajl/" +arch="all" +license="BSD" +depends="" +makedepends="cmake" +install="" +subpackages="$pkgname-dev $pkgname-tools" + +# How to create archive from git. pkgver needs to be a git tag. +# +# git clone https://github.com/lloyd/yajl.git +# cd yajl +# git archive --format tar.gz --prefix yajl-$pkgver/ -o yajl-$pkgver.tar.gz $pkgver +# scp yajl-$pkgver.tar.gz dev.alpinelinux.org:/archive/yajl/ + +source="http://dev.alpinelinux.org/archive/yajl/yajl-$pkgver.tar.gz + libm.patch" + +_builddir="$srcdir"/yajl-$pkgver + +prepare() { + local i + cd "$_builddir" + for i in $source; do + case $i in + *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; + esac + done +} + +build() { + cd "$_builddir" + cmake -DCMAKE_INSTALL_PREFIX="/usr" . || return 1 + make +} + +package() { + cd "$_builddir" + make install DESTDIR="$pkgdir" || return 1 + mv "$pkgdir"/usr/share/pkgconfig "$pkgdir"/usr/lib/ +} + +tools() { + pkgdesc="JSON tools based on Yajl" + mkdir -p "$subpkgdir"/usr/ + mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ +} + + +md5sums="f5d31df70eb7cc522a5fa2fe06336022 yajl-2.0.3.tar.gz +64ae0008a567c3246ce805b6495d4c54 libm.patch" diff --git a/main/yajl/libm.patch b/main/yajl/libm.patch new file mode 100644 index 000000000..9d22369ec --- /dev/null +++ b/main/yajl/libm.patch @@ -0,0 +1,45 @@ +diff --git a/example/CMakeLists.txt b/example/CMakeLists.txt +index 29cee35..387366e 100644 +--- a/example/CMakeLists.txt ++++ b/example/CMakeLists.txt +@@ -20,4 +20,4 @@ LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) + + ADD_EXECUTABLE(parse_config ${SRCS}) + +-TARGET_LINK_LIBRARIES(parse_config yajl_s) ++TARGET_LINK_LIBRARIES(parse_config yajl_s m) +diff --git a/reformatter/CMakeLists.txt b/reformatter/CMakeLists.txt +index da4032b..d48e218 100644 +--- a/reformatter/CMakeLists.txt ++++ b/reformatter/CMakeLists.txt +@@ -26,7 +26,7 @@ LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) + + ADD_EXECUTABLE(json_reformat ${SRCS}) + +-TARGET_LINK_LIBRARIES(json_reformat yajl_s) ++TARGET_LINK_LIBRARIES(json_reformat yajl_s m) + + # copy the binary into the output directory + GET_TARGET_PROPERTY(binPath json_reformat LOCATION) +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index e36b736..85083bf 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -38,6 +38,7 @@ SET(LIBRARY_OUTPUT_PATH ${libDir}) + ADD_LIBRARY(yajl_s STATIC ${SRCS} ${HDRS} ${PUB_HDRS}) + + ADD_LIBRARY(yajl SHARED ${SRCS} ${HDRS} ${PUB_HDRS}) ++TARGET_LINK_LIBRARIES(yajl m) + + #### setup shared library version number + SET_TARGET_PROPERTIES(yajl PROPERTIES +diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt +index 153288c..c5fa974 100644 +--- a/test/CMakeLists.txt ++++ b/test/CMakeLists.txt +@@ -20,4 +20,4 @@ LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) + + ADD_EXECUTABLE(yajl_test ${SRCS}) + +-TARGET_LINK_LIBRARIES(yajl_test yajl_s) ++TARGET_LINK_LIBRARIES(yajl_test yajl_s m) diff --git a/testing/yajl/APKBUILD b/testing/yajl/APKBUILD deleted file mode 100644 index 7a0d6e8ac..000000000 --- a/testing/yajl/APKBUILD +++ /dev/null @@ -1,56 +0,0 @@ -# Maintainer: Natanael Copa -pkgname=yajl -pkgver=2.0.3 -pkgrel=0 -pkgdesc="Yet Another JSON Library (YAJL)" -url="http://lloyd.github.com/yajl/" -arch="all" -license="BSD" -depends="" -makedepends="cmake" -install="" -subpackages="$pkgname-dev $pkgname-tools" - -# How to create archive from git. pkgver needs to be a git tag. -# -# git clone https://github.com/lloyd/yajl.git -# cd yajl -# git archive --format tar.gz --prefix yajl-$pkgver/ -o yajl-$pkgver.tar.gz $pkgver -# scp yajl-$pkgver.tar.gz dev.alpinelinux.org:/archive/yajl/ - -source="http://dev.alpinelinux.org/archive/yajl/yajl-$pkgver.tar.gz - libm.patch" - -_builddir="$srcdir"/yajl-$pkgver - -prepare() { - local i - cd "$_builddir" - for i in $source; do - case $i in - *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; - esac - done -} - -build() { - cd "$_builddir" - cmake -DCMAKE_INSTALL_PREFIX="/usr" . || return 1 - make -} - -package() { - cd "$_builddir" - make install DESTDIR="$pkgdir" || return 1 - mv "$pkgdir"/usr/share/pkgconfig "$pkgdir"/usr/lib/ -} - -tools() { - pkgdesc="JSON tools based on Yajl" - mkdir -p "$subpkgdir"/usr/ - mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ -} - - -md5sums="f5d31df70eb7cc522a5fa2fe06336022 yajl-2.0.3.tar.gz -64ae0008a567c3246ce805b6495d4c54 libm.patch" diff --git a/testing/yajl/libm.patch b/testing/yajl/libm.patch deleted file mode 100644 index 9d22369ec..000000000 --- a/testing/yajl/libm.patch +++ /dev/null @@ -1,45 +0,0 @@ -diff --git a/example/CMakeLists.txt b/example/CMakeLists.txt -index 29cee35..387366e 100644 ---- a/example/CMakeLists.txt -+++ b/example/CMakeLists.txt -@@ -20,4 +20,4 @@ LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) - - ADD_EXECUTABLE(parse_config ${SRCS}) - --TARGET_LINK_LIBRARIES(parse_config yajl_s) -+TARGET_LINK_LIBRARIES(parse_config yajl_s m) -diff --git a/reformatter/CMakeLists.txt b/reformatter/CMakeLists.txt -index da4032b..d48e218 100644 ---- a/reformatter/CMakeLists.txt -+++ b/reformatter/CMakeLists.txt -@@ -26,7 +26,7 @@ LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) - - ADD_EXECUTABLE(json_reformat ${SRCS}) - --TARGET_LINK_LIBRARIES(json_reformat yajl_s) -+TARGET_LINK_LIBRARIES(json_reformat yajl_s m) - - # copy the binary into the output directory - GET_TARGET_PROPERTY(binPath json_reformat LOCATION) -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index e36b736..85083bf 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -38,6 +38,7 @@ SET(LIBRARY_OUTPUT_PATH ${libDir}) - ADD_LIBRARY(yajl_s STATIC ${SRCS} ${HDRS} ${PUB_HDRS}) - - ADD_LIBRARY(yajl SHARED ${SRCS} ${HDRS} ${PUB_HDRS}) -+TARGET_LINK_LIBRARIES(yajl m) - - #### setup shared library version number - SET_TARGET_PROPERTIES(yajl PROPERTIES -diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt -index 153288c..c5fa974 100644 ---- a/test/CMakeLists.txt -+++ b/test/CMakeLists.txt -@@ -20,4 +20,4 @@ LINK_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/../${YAJL_DIST_NAME}/lib) - - ADD_EXECUTABLE(yajl_test ${SRCS}) - --TARGET_LINK_LIBRARIES(yajl_test yajl_s) -+TARGET_LINK_LIBRARIES(yajl_test yajl_s m) -- cgit v1.2.3