Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 24 Sep 2013 22:24:50 +0000 (UTC)
From:      "Vanilla I. Shu" <vanilla@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r328206 - in head/devel/jansson: . files
Message-ID:  <201309242224.r8OMOoun092342@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: vanilla
Date: Tue Sep 24 22:24:50 2013
New Revision: 328206
URL: http://svnweb.freebsd.org/changeset/ports/328206

Log:
  1: upgrade to latest version (2.5)
  2: add support of stage dir.

Modified:
  head/devel/jansson/Makefile
  head/devel/jansson/distinfo
  head/devel/jansson/files/patch-src_hashtable.c
  head/devel/jansson/files/patch-src_jansson.h
  head/devel/jansson/files/patch-src_value.c
  head/devel/jansson/pkg-plist

Modified: head/devel/jansson/Makefile
==============================================================================
--- head/devel/jansson/Makefile	Tue Sep 24 22:23:45 2013	(r328205)
+++ head/devel/jansson/Makefile	Tue Sep 24 22:24:50 2013	(r328206)
@@ -2,7 +2,7 @@
 # $FreeBSD$
 
 PORTNAME=	jansson
-PORTVERSION=	2.4
+PORTVERSION=	2.5
 CATEGORIES=	devel
 MASTER_SITES=	http://www.digip.org/jansson/releases/
 
@@ -14,5 +14,4 @@ USE_BZIP2=	yes
 USE_LDCONFIG=	yes
 GNU_CONFIGURE=	yes
 
-NO_STAGE=	yes
 .include <bsd.port.mk>

Modified: head/devel/jansson/distinfo
==============================================================================
--- head/devel/jansson/distinfo	Tue Sep 24 22:23:45 2013	(r328205)
+++ head/devel/jansson/distinfo	Tue Sep 24 22:24:50 2013	(r328206)
@@ -1,2 +1,2 @@
-SHA256 (jansson-2.4.tar.bz2) = de589151586e0766a08921f3167953a3ed62079be828bcc949cd9b2b6dcfaf90
-SIZE (jansson-2.4.tar.bz2) = 309860
+SHA256 (jansson-2.5.tar.bz2) = 262f5a3e9ad8f5d8b3c8683e8c57b5148ff0ad97cfe3d6f10b8b15ece126e4c7
+SIZE (jansson-2.5.tar.bz2) = 312937

Modified: head/devel/jansson/files/patch-src_hashtable.c
==============================================================================
--- head/devel/jansson/files/patch-src_hashtable.c	Tue Sep 24 22:23:45 2013	(r328205)
+++ head/devel/jansson/files/patch-src_hashtable.c	Tue Sep 24 22:24:50 2013	(r328206)
@@ -1,16 +1,16 @@
---- src/hashtable.c.orig	2012-03-15 23:19:46.000000000 +0800
-+++ src/hashtable.c	2012-03-15 23:21:20.000000000 +0800
+--- src/hashtable.c.orig	2013-09-20 01:47:31.000000000 +0800
++++ src/hashtable.c	2013-09-25 06:17:31.000000000 +0800
 @@ -118,10 +118,10 @@ static int hashtable_do_del(hashtable_t 
  {
      pair_t *pair;
      bucket_t *bucket;
 -    size_t index;
-+    size_t my_index;
++    size_t ind;
  
 -    index = hash % num_buckets(hashtable);
 -    bucket = &hashtable->buckets[index];
-+    my_index = hash % num_buckets(hashtable);
-+    bucket = &hashtable->buckets[my_index];
++    ind = hash % num_buckets(hashtable);
++    bucket = &hashtable->buckets[ind];
  
      pair = hashtable_find_pair(hashtable, bucket, key, hash);
      if(!pair)
@@ -19,7 +19,7 @@
      list_t *list, *next;
      pair_t *pair;
 -    size_t i, index, new_size;
-+    size_t i, my_index, new_size;
++    size_t i, ind, new_size;
  
      jsonp_free(hashtable->buckets);
  
@@ -29,8 +29,8 @@
          pair = list_to_pair(list);
 -        index = pair->hash % new_size;
 -        insert_to_bucket(hashtable, &hashtable->buckets[index], &pair->list);
-+        my_index = pair->hash % new_size;
-+        insert_to_bucket(hashtable, &hashtable->buckets[my_index], &pair->list);
++        ind = pair->hash % new_size;
++        insert_to_bucket(hashtable, &hashtable->buckets[ind], &pair->list);
      }
  
      return 0;
@@ -39,7 +39,7 @@
      pair_t *pair;
      bucket_t *bucket;
 -    size_t hash, index;
-+    size_t hash, my_index;
++    size_t hash, ind;
  
      /* rehash if the load ratio exceeds 1 */
      if(hashtable->size >= num_buckets(hashtable))
@@ -49,8 +49,8 @@
      hash = hash_str(key);
 -    index = hash % num_buckets(hashtable);
 -    bucket = &hashtable->buckets[index];
-+    my_index = hash % num_buckets(hashtable);
-+    bucket = &hashtable->buckets[my_index];
++    ind = hash % num_buckets(hashtable);
++    bucket = &hashtable->buckets[ind];
      pair = hashtable_find_pair(hashtable, bucket, key, hash);
  
      if(pair)

Modified: head/devel/jansson/files/patch-src_jansson.h
==============================================================================
--- head/devel/jansson/files/patch-src_jansson.h	Tue Sep 24 22:23:45 2013	(r328205)
+++ head/devel/jansson/files/patch-src_jansson.h	Tue Sep 24 22:24:50 2013	(r328206)
@@ -1,39 +1,33 @@
---- src/jansson.h.orig	2011-04-02 22:38:00.000000000 +0800
-+++ src/jansson.h	2011-04-02 22:38:38.000000000 +0800
-@@ -152,18 +152,18 @@ int json_object_iter_set(json_t *object,
+--- src/jansson.h.orig	2013-09-25 06:11:34.000000000 +0800
++++ src/jansson.h	2013-09-25 06:13:20.000000000 +0800
+@@ -148,10 +148,10 @@ int json_object_iter_set_new(json_t *obj
+         key && (value = json_object_iter_value(json_object_key_to_iter(key))); \
+         key = json_object_iter_key(json_object_iter_next(object, json_object_key_to_iter(key))))
+ 
+-#define json_array_foreach(array, index, value) \
+-	for(index = 0; \
+-		index < json_array_size(array) && (value = json_array_get(array, index)); \
+-		index++)
++#define json_array_foreach(array, ind, value) \
++	for(ind = 0; \
++		ind < json_array_size(array) && (value = json_array_get(array, ind)); \
++		ind++)
+ 
+ static JSON_INLINE
+ int json_object_set(json_t *object, const char *key, json_t *value)
+@@ -172,11 +172,11 @@ int json_object_iter_set(json_t *object,
  }
  
  size_t json_array_size(const json_t *array);
 -json_t *json_array_get(const json_t *array, size_t index);
 -int json_array_set_new(json_t *array, size_t index, json_t *value);
-+json_t *json_array_get(const json_t *array, size_t my_index);
-+int json_array_set_new(json_t *array, size_t my_index, json_t *value);
++json_t *json_array_get(const json_t *array, size_t ind);
++int json_array_set_new(json_t *array, size_t ind, json_t *value);
  int json_array_append_new(json_t *array, json_t *value);
 -int json_array_insert_new(json_t *array, size_t index, json_t *value);
 -int json_array_remove(json_t *array, size_t index);
-+int json_array_insert_new(json_t *array, size_t my_index, json_t *value);
-+int json_array_remove(json_t *array, size_t my_index);
++int json_array_insert_new(json_t *array, size_t ind, json_t *value);
++int json_array_remove(json_t *array, size_t ind);
  int json_array_clear(json_t *array);
  int json_array_extend(json_t *array, json_t *other);
  
- static JSON_INLINE
--int json_array_set(json_t *array, size_t index, json_t *value)
-+int json_array_set(json_t *array, size_t my_index, json_t *value)
- {
--    return json_array_set_new(array, index, json_incref(value));
-+    return json_array_set_new(array, my_index, json_incref(value));
- }
- 
- static JSON_INLINE
-@@ -173,9 +173,9 @@ int json_array_append(json_t *array, jso
- }
- 
- static JSON_INLINE
--int json_array_insert(json_t *array, size_t index, json_t *value)
-+int json_array_insert(json_t *array, size_t my_index, json_t *value)
- {
--    return json_array_insert_new(array, index, json_incref(value));
-+    return json_array_insert_new(array, my_index, json_incref(value));
- }
- 
- const char *json_string_value(const json_t *string);

Modified: head/devel/jansson/files/patch-src_value.c
==============================================================================
--- head/devel/jansson/files/patch-src_value.c	Tue Sep 24 22:23:45 2013	(r328205)
+++ head/devel/jansson/files/patch-src_value.c	Tue Sep 24 22:24:50 2013	(r328206)
@@ -1,11 +1,11 @@
---- src/value.c.orig	2011-04-02 22:38:44.000000000 +0800
-+++ src/value.c	2011-04-02 22:39:37.000000000 +0800
-@@ -401,20 +401,20 @@ size_t json_array_size(const json_t *jso
+--- src/value.c.orig	2013-09-25 06:13:36.000000000 +0800
++++ src/value.c	2013-09-25 06:15:37.000000000 +0800
+@@ -360,20 +360,20 @@ size_t json_array_size(const json_t *jso
      return json_to_array(json)->entries;
  }
  
 -json_t *json_array_get(const json_t *json, size_t index)
-+json_t *json_array_get(const json_t *json, size_t my_index)
++json_t *json_array_get(const json_t *json, size_t ind)
  {
      json_array_t *array;
      if(!json_is_array(json))
@@ -13,24 +13,24 @@
      array = json_to_array(json);
  
 -    if(index >= array->entries)
-+    if(my_index >= array->entries)
++    if(ind >= array->entries)
          return NULL;
  
 -    return array->table[index];
-+    return array->table[my_index];
++    return array->table[ind];
  }
  
 -int json_array_set_new(json_t *json, size_t index, json_t *value)
-+int json_array_set_new(json_t *json, size_t my_index, json_t *value)
++int json_array_set_new(json_t *json, size_t ind, json_t *value)
  {
      json_array_t *array;
  
-@@ -428,14 +428,14 @@ int json_array_set_new(json_t *json, siz
+@@ -387,14 +387,14 @@ int json_array_set_new(json_t *json, siz
      }
      array = json_to_array(json);
  
 -    if(index >= array->entries)
-+    if(my_index >= array->entries)
++    if(ind >= array->entries)
      {
          json_decref(value);
          return -1;
@@ -38,70 +38,73 @@
  
 -    json_decref(array->table[index]);
 -    array->table[index] = value;
-+    json_decref(array->table[my_index]);
-+    array->table[my_index] = value;
++    json_decref(array->table[ind]);
++    array->table[ind] = value;
  
      return 0;
  }
-@@ -507,7 +507,7 @@ int json_array_append_new(json_t *json, 
+@@ -466,7 +466,7 @@ int json_array_append_new(json_t *json, 
      return 0;
  }
  
 -int json_array_insert_new(json_t *json, size_t index, json_t *value)
-+int json_array_insert_new(json_t *json, size_t my_index, json_t *value)
++int json_array_insert_new(json_t *json, size_t ind, json_t *value)
  {
      json_array_t *array;
      json_t **old_table;
-@@ -521,7 +521,7 @@ int json_array_insert_new(json_t *json, 
+@@ -480,7 +480,7 @@ int json_array_insert_new(json_t *json, 
      }
      array = json_to_array(json);
  
 -    if(index > array->entries) {
-+    if(my_index > array->entries) {
++    if(ind > array->entries) {
          json_decref(value);
          return -1;
      }
-@@ -533,21 +533,21 @@ int json_array_insert_new(json_t *json, 
+@@ -492,21 +492,21 @@ int json_array_insert_new(json_t *json, 
      }
  
      if(old_table != array->table) {
 -        array_copy(array->table, 0, old_table, 0, index);
 -        array_copy(array->table, index + 1, old_table, index,
 -                   array->entries - index);
-+        array_copy(array->table, 0, old_table, 0, my_index);
-+        array_copy(array->table, my_index + 1, old_table, my_index,
-+                   array->entries - my_index);
++        array_copy(array->table, 0, old_table, 0, ind);
++        array_copy(array->table, ind + 1, old_table, ind,
++                   array->entries - ind);
          jsonp_free(old_table);
      }
      else
 -        array_move(array, index + 1, index, array->entries - index);
-+        array_move(array, my_index + 1, my_index, array->entries - my_index);
++        array_move(array, ind + 1, ind, array->entries - ind);
  
 -    array->table[index] = value;
-+    array->table[my_index] = value;
++    array->table[ind] = value;
      array->entries++;
  
      return 0;
  }
  
 -int json_array_remove(json_t *json, size_t index)
-+int json_array_remove(json_t *json, size_t my_index)
++int json_array_remove(json_t *json, size_t ind)
  {
      json_array_t *array;
  
-@@ -555,12 +555,12 @@ int json_array_remove(json_t *json, size
+@@ -514,14 +514,14 @@ int json_array_remove(json_t *json, size
          return -1;
      array = json_to_array(json);
  
 -    if(index >= array->entries)
-+    if(my_index >= array->entries)
++    if(ind >= array->entries)
          return -1;
  
 -    json_decref(array->table[index]);
-+    json_decref(array->table[my_index]);
++    json_decref(array->table[ind]);
+ 
+     /* If we're removing the last element, nothing has to be moved */
+-    if(index < array->entries - 1)
+-        array_move(array, index, index + 1, array->entries - index - 1);
++    if(ind < array->entries - 1)
++        array_move(array, ind, ind + 1, array->entries - ind - 1);
  
--    array_move(array, index, index + 1, array->entries - index);
-+    array_move(array, my_index, my_index + 1, array->entries - my_index);
      array->entries--;
  
-     return 0;

Modified: head/devel/jansson/pkg-plist
==============================================================================
--- head/devel/jansson/pkg-plist	Tue Sep 24 22:23:45 2013	(r328205)
+++ head/devel/jansson/pkg-plist	Tue Sep 24 22:24:50 2013	(r328206)
@@ -3,5 +3,5 @@ include/jansson_config.h
 lib/libjansson.a
 lib/libjansson.la
 lib/libjansson.so
-lib/libjansson.so.8
+lib/libjansson.so.9
 libdata/pkgconfig/jansson.pc



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201309242224.r8OMOoun092342>