View | Details | Raw Unified | Return to bug 106197
Collapse All | Expand All

(-)Makefile (-3 / +3 lines)
Lines 8-14 Link Here
8
8
9
PORTNAME=	ixlib
9
PORTNAME=	ixlib
10
PORTVERSION=	0.96.2
10
PORTVERSION=	0.96.2
11
PORTREVISION=	3
11
PORTREVISION=	4
12
CATEGORIES=	devel
12
CATEGORIES=	devel
13
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
13
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
14
MASTER_SITE_SUBDIR=	${PORTNAME}
14
MASTER_SITE_SUBDIR=	${PORTNAME}
Lines 27-34 Link Here
27
27
28
.include <bsd.port.pre.mk>
28
.include <bsd.port.pre.mk>
29
29
30
.if ${ARCH} != "i386" || ${OSVERSION} >= 500000
30
.if ${ARCH} != "i386"
31
BROKEN=		Does not compile on !i386 or on FreeBSD >= 5.x
31
BROKEN=		Does not compile on !i386
32
.endif
32
.endif
33
33
34
pre-configure:
34
pre-configure:
(-)files/patch-src::ixlib_garbage.hh (+227 lines)
Added Link Here
1
--- src/ixlib_garbage.hh.orig	Tue Jun 19 16:16:29 2001
2
+++ src/ixlib_garbage.hh	Fri Dec  1 19:56:04 2006
3
@@ -126,24 +126,24 @@
4
       // compiler generates one, which is *ahem* - fatal
5
       ref(ref const &src)
6
         : ref_base<T>(src) {
7
-	reference_manager_keeper<T_Managed>::Manager.addReference(Instance);
8
+	reference_manager_keeper<T_Managed>::Manager.addReference(this->Instance);
9
 	}
10
       template<class T2>
11
       ref(ref<T2,T_Managed> const &src)
12
         : ref_base<T>(src.get()) {
13
-	reference_manager_keeper<T_Managed>::Manager.addReference(Instance);
14
+	reference_manager_keeper<T_Managed>::Manager.addReference(this->Instance);
15
 	}
16
       template<class T2>
17
       ref(no_free_ref<T2,T_Managed> const &src)
18
         : ref_base<T>(src.get()) {
19
-	reference_manager_keeper<T_Managed>::Manager.addReference(Instance);
20
+	reference_manager_keeper<T_Managed>::Manager.addReference(this->Instance);
21
 	}
22
       ref(T *instance = NULL)
23
         : ref_base<T>(instance) {
24
-	reference_manager_keeper<T_Managed>::Manager.addReference(Instance);
25
+	reference_manager_keeper<T_Managed>::Manager.addReference(this->Instance);
26
 	}
27
       ~ref() {
28
-        reference_manager_keeper<T_Managed>::Manager.freeReference(Instance);
29
+        reference_manager_keeper<T_Managed>::Manager.freeReference(this->Instance);
30
 	}
31
 	
32
       ref &operator=(ref const &src) {
33
@@ -157,20 +157,20 @@
34
       
35
       // methods
36
       void release() {
37
-	reference_manager_keeper<T_Managed>::Manager.freeReference(Instance);
38
-	Instance = NULL;
39
+	reference_manager_keeper<T_Managed>::Manager.freeReference(this->Instance);
40
+	this->Instance = NULL;
41
 	}
42
       void set(T *instance) {
43
-        if (instance == Instance) return;
44
+        if (instance == this->Instance) return;
45
 	
46
-	reference_manager_keeper<T_Managed>::Manager.freeReference(Instance);
47
-	Instance = instance;
48
-	reference_manager_keeper<T_Managed>::Manager.addReference(Instance);
49
+	reference_manager_keeper<T_Managed>::Manager.freeReference(this->Instance);
50
+	this->Instance = instance;
51
+	reference_manager_keeper<T_Managed>::Manager.addReference(this->Instance);
52
         }
53
       T *releaseFromGCArena() {
54
-        T *oldinst = Instance;
55
-	reference_manager_keeper<T_Managed>::Manager.forgetReference(Instance);
56
-	Instance = NULL;
57
+        T *oldinst = this->Instance;
58
+	reference_manager_keeper<T_Managed>::Manager.forgetReference(this->Instance);
59
+	this->Instance = NULL;
60
 	return oldinst;
61
         }
62
     };
63
@@ -200,24 +200,24 @@
64
       // compiler generates one, which is *ahem* - fatal
65
       no_free_ref(no_free_ref const &src)
66
         : ref_base<T>(src) {
67
-	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(Instance);
68
+	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(this->Instance);
69
 	}
70
       template<class T2>
71
       no_free_ref(ref<T2,T_Managed> const &src)
72
         : ref_base<T>(src.get()) {
73
-	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(Instance);
74
+	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(this->Instance);
75
 	}
76
       template<class T2>
77
       no_free_ref(no_free_ref<T2,T_Managed> const &src)
78
         : ref_base<T>(src.get()) {
79
-	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(Instance);
80
+	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(this->Instance);
81
 	}
82
       no_free_ref(T *instance = NULL)
83
         : ref_base<T>(instance) {
84
-	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(Instance);
85
+	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(this->Instance);
86
 	}
87
       ~no_free_ref() {
88
-        reference_manager_keeper<T_Managed>::Manager.removeNoFreeReference(Instance);
89
+        reference_manager_keeper<T_Managed>::Manager.removeNoFreeReference(this->Instance);
90
 	}
91
 	
92
       // assignment
93
@@ -232,20 +232,20 @@
94
       
95
       // methods
96
       void release() {
97
-	reference_manager_keeper<T_Managed>::Manager.removeNoFreeReference(Instance);
98
-	Instance = NULL;
99
+	reference_manager_keeper<T_Managed>::Manager.removeNoFreeReference(this->Instance);
100
+	this->Instance = NULL;
101
 	}
102
       void set(T *instance) {
103
-        if (instance == Instance) return;
104
+        if (instance == this->Instance) return;
105
 	
106
-	reference_manager_keeper<T_Managed>::Manager.removeNoFreeReference(Instance);
107
-	Instance = instance;
108
-	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(Instance);
109
+	reference_manager_keeper<T_Managed>::Manager.removeNoFreeReference(this->Instance);
110
+	this->Instance = instance;
111
+	reference_manager_keeper<T_Managed>::Manager.addNoFreeReference(this->Instance);
112
         }
113
       T *releaseFromGCArena() {
114
-        T *oldinst = Instance;
115
-	reference_manager_keeper<T_Managed>::Manager.forgetReference(Instance);
116
-	Instance = NULL;
117
+        T *oldinst = this->Instance;
118
+	reference_manager_keeper<T_Managed>::Manager.forgetReference(this->Instance);
119
+	this->Instance = NULL;
120
 	return oldinst;
121
         }
122
     };
123
@@ -265,14 +265,14 @@
124
     public:
125
       dynamic_ref(dynamic_ref const &src)
126
         : ref_base<T>(src),Manager(src.Manager) {
127
-	Manager.addReference(Instance);
128
+	Manager.addReference(this->Instance);
129
 	}
130
       dynamic_ref(reference_manager<T> &mgr,T *instance = NULL)
131
         : ref_base<T>(instance),Manager(mgr) {
132
-	Manager.addReference(Instance);
133
+	Manager.addReference(this->Instance);
134
 	}
135
       ~dynamic_ref() {
136
-        Manager.freeReference(Instance);
137
+        Manager.freeReference(this->Instance);
138
 	}
139
       
140
       // assignment
141
@@ -287,20 +287,20 @@
142
 
143
       // methods
144
       void release() {
145
-	Manager.freeReference(Instance);
146
-	Instance = NULL;
147
+	Manager.freeReference(this->Instance);
148
+	this->Instance = NULL;
149
 	}
150
       void set(T *instance) {
151
-        if (instance == Instance) return;
152
+        if (instance == this->Instance) return;
153
 	
154
-	Manager.freeReference(Instance);
155
-	Instance = instance;
156
-	Manager.addReference(Instance);
157
+	Manager.freeReference(this->Instance);
158
+	this->Instance = instance;
159
+	Manager.addReference(this->Instance);
160
         }
161
       T *releaseFromGCArena() {
162
-        T *oldinst = Instance;
163
-	Manager.forgetReference(Instance);
164
-	Instance = NULL;
165
+        T *oldinst = this->Instance;
166
+	Manager.forgetReference(this->Instance);
167
+	this->Instance = NULL;
168
 	return oldinst;
169
         }
170
     };
171
@@ -330,14 +330,14 @@
172
     public:
173
       no_free_dynamic_ref(no_free_dynamic_ref const &src)
174
         : ref_base<T>(src),Manager(src.Manager) {
175
-	Manager.addNoFreeReference(Instance);
176
+	Manager.addNoFreeReference(this->Instance);
177
 	}
178
       no_free_dynamic_ref(reference_manager<T> &mgr,T *instance = NULL)
179
         : ref_base<T>(instance),Manager(mgr) {
180
-	Manager.addNoFreeReference(Instance);
181
+	Manager.addNoFreeReference(this->Instance);
182
 	}
183
       ~no_free_dynamic_ref() {
184
-        Manager.removeNoFreeReference(Instance);
185
+        Manager.removeNoFreeReference(this->Instance);
186
 	}
187
       
188
       // assignment
189
@@ -352,20 +352,20 @@
190
 
191
       // methods
192
       void release() {
193
-	Manager.removeNoFreeReference(Instance);
194
-	Instance = NULL;
195
+	Manager.removeNoFreeReference(this->Instance);
196
+	this->Instance = NULL;
197
 	}
198
       void set(T *instance) {
199
-        if (instance == Instance) return;
200
+        if (instance == this->Instance) return;
201
 	
202
-	Manager.removeNoFreeReference(Instance);
203
-	Instance = instance;
204
-	Manager.addNoFreeReference(Instance);
205
+	Manager.removeNoFreeReference(this->Instance);
206
+	this->Instance = instance;
207
+	Manager.addNoFreeReference(this->Instance);
208
         }
209
       T *releaseFromGCArena() {
210
-        T *oldinst = Instance;
211
-	Manager.forgetReference(Instance);
212
-	Instance = NULL;
213
+        T *oldinst = this->Instance;
214
+	Manager.forgetReference(this->Instance);
215
+	this->Instance = NULL;
216
 	return oldinst;
217
         }
218
     };
219
@@ -482,7 +482,7 @@
220
 
221
 
222
   #define IXLIB_GARBAGE_DECLARE_MANAGER(TYPE) \
223
-    ixion::reference_manager<TYPE> ixion::reference_manager_keeper<TYPE>::Manager;
224
+    template <> ixion::reference_manager<TYPE> ixion::reference_manager_keeper<TYPE>::Manager = ixion::reference_manager<TYPE>();
225
   }
226
 
227
 
(-)files/patch-src::ixlib_numeric.hh (+67 lines)
Added Link Here
1
--- src/ixlib_numeric.hh.orig	Thu Mar 22 16:16:25 2001
2
+++ src/ixlib_numeric.hh	Thu Nov 30 23:11:52 2006
3
@@ -67,56 +67,56 @@
4
 
5
 
6
 // Primitive inlines ---------------------------------------------------------
7
-  inline signed short ixion::sgn(signed long value) {
8
+  inline signed short sgn(signed long value) {
9
     return (value<0) ? -1 : ( (value>0) ? 1 : 0);
10
     }
11
   
12
   
13
   
14
   
15
-  inline bool ixion::getBit(unsigned long value,char bit) {
16
+  inline bool getBit(unsigned long value,char bit) {
17
     return (value >> bit) & 1;
18
     }
19
   
20
   
21
   
22
   
23
-  inline TUnsigned8 ixion::hiByte(TUnsigned16 value) {
24
+  inline TUnsigned8 hiByte(TUnsigned16 value) {
25
     return value >> 8;
26
     }
27
   
28
   
29
   
30
   
31
-  inline TUnsigned16 ixion::hiWord(TUnsigned32 value) {
32
+  inline TUnsigned16 hiWord(TUnsigned32 value) {
33
     return value >> 16;
34
     }
35
   
36
   
37
   
38
   
39
-  inline TUnsigned8 ixion::loByte(TUnsigned16 value) {
40
+  inline TUnsigned8 loByte(TUnsigned16 value) {
41
     return value & 0xff;
42
     }
43
   
44
   
45
   
46
   
47
-  inline TUnsigned16 ixion::loWord(TUnsigned32 value) {
48
+  inline TUnsigned16 loWord(TUnsigned32 value) {
49
     return value & 0xffff;
50
     }
51
   
52
   
53
   
54
   
55
-  inline TUnsigned16 ixion::makeWord(TUnsigned8 hi,TUnsigned8 lo) {
56
+  inline TUnsigned16 makeWord(TUnsigned8 hi,TUnsigned8 lo) {
57
     return (TUnsigned16) hi << 8 | lo;
58
     }
59
   
60
   
61
   
62
   
63
-  inline TUnsigned32 ixion::makeDWord(TUnsigned16 hi,TUnsigned16 lo) {
64
+  inline TUnsigned32 makeDWord(TUnsigned16 hi,TUnsigned16 lo) {
65
     return (TUnsigned32) hi << 16 | lo;
66
     }
67
   }
(-)files/patch-src::ixlib_re.hh (-2 / +47 lines)
Lines 1-5 Link Here
1
--- src/ixlib_re.hh.orig	Fri Nov 28 11:46:14 2003
1
--- src/ixlib_re.hh.orig	Tue Jun 19 16:16:29 2001
2
+++ src/ixlib_re.hh	Fri Nov 28 11:53:24 2003
2
+++ src/ixlib_re.hh	Fri Dec  1 18:36:04 2006
3
@@ -163,7 +163,7 @@
3
@@ -163,7 +163,7 @@
4
     
4
     
5
         struct backtrack_stack_entry {
5
         struct backtrack_stack_entry {
Lines 9-11 Link Here
9
           };
9
           };
10
   
10
   
11
         public:
11
         public:
12
@@ -210,7 +210,7 @@
13
       class any_matcher : public matcher {
14
         public:
15
           any_matcher() { 
16
-            MatchLength = 1; 
17
+            this->MatchLength = 1; 
18
             }
19
 
20
 	  matcher *duplicate() const;
21
@@ -229,7 +229,7 @@
22
       class start_matcher : public matcher {
23
         public:
24
           start_matcher() { 
25
-            MatchLength = 0; 
26
+            this->MatchLength = 0; 
27
             }
28
 
29
 	  matcher *duplicate() const;
30
@@ -246,7 +246,7 @@
31
       class end_matcher : public matcher {
32
         public:
33
           end_matcher() { 
34
-            MatchLength = 0;
35
+            this->MatchLength = 0;
36
             }
37
 
38
 	  matcher *duplicate() const;
39
@@ -263,7 +263,7 @@
40
       class backref_open_matcher : public matcher {
41
         public:
42
           backref_open_matcher() { 
43
-            MatchLength = 0; 
44
+            this->MatchLength = 0; 
45
             }
46
 
47
 	  matcher *duplicate() const;
48
@@ -280,7 +280,7 @@
49
       class backref_close_matcher : public matcher {
50
         public:
51
           backref_close_matcher() { 
52
-            MatchLength = 0; 
53
+            this->MatchLength = 0; 
54
             }
55
 
56
 	  matcher *duplicate() const;
(-)files/patch-src::ixlib_re_impl.hh (-7 / +62 lines)
Lines 1-5 Link Here
1
--- src/ixlib_re_impl.hh.orig	Fri Nov 28 11:43:40 2003
1
--- src/ixlib_re_impl.hh.orig	Tue Jun 19 16:16:29 2001
2
+++ src/ixlib_re_impl.hh	Fri Nov 28 12:55:23 2003
2
+++ src/ixlib_re_impl.hh	Fri Dec  1 18:38:10 2006
3
@@ -38,7 +38,7 @@
3
@@ -38,7 +38,7 @@
4
 
4
 
5
 
5
 
Lines 36-42 Link Here
36
   quantifier *dupe = new quantifier();
36
   quantifier *dupe = new quantifier();
37
   dupe->copy(this);
37
   dupe->copy(this);
38
   return dupe;
38
   return dupe;
39
@@ -328,7 +328,7 @@
39
@@ -239,7 +239,7 @@
40
   if (quant_min == 0) quant_min = 1;
41
   
42
   TSize max_count = candidate.size() - at;
43
-  if (Next) max_count -= Next->minimumSubsequentMatchLength();
44
+  if (this->Next) max_count -= this->Next->minimumSubsequentMatchLength();
45
   max_count = max_count/quant_min + 1;
46
   
47
   if (MaxValid) max_count = NUM_MIN(max_count,MaxCount);
48
@@ -278,7 +278,7 @@
49
       }
50
     
51
     if (successful_indices.size()) {
52
-      MatchLength = successful_indices.top().Index - at;
53
+      this->MatchLength = successful_indices.top().Index - at;
54
       return true;
55
       }
56
     else return false;
57
@@ -286,7 +286,7 @@
58
   else {
59
     for (TSize c = 0;c <= remcount;c++) {
60
       if (matchNext(brstack,candidate,idx)) {
61
-        MatchLength = idx-at;
62
+        this->MatchLength = idx-at;
63
         return true;
64
         }
65
       // following part runs once too much, effectively: 
66
@@ -321,14 +321,14 @@
67
 template<class T>
68
 ixion::regex<T>::sequence_matcher::sequence_matcher(T const &matchstr)
69
   : MatchStr(matchstr) { 
70
-  MatchLength = MatchStr.size(); 
71
+  this->MatchLength = MatchStr.size(); 
72
   }
73
 
74
 
40
 
75
 
41
 
76
 
42
 template<class T>
77
 template<class T>
Lines 135-141 Link Here
135
   matcher::setNext(next);
170
   matcher::setNext(next);
136
   Connector.setNext(next,false);
171
   Connector.setNext(next,false);
137
   }
172
   }
138
@@ -524,7 +524,7 @@
173
@@ -524,13 +524,13 @@
139
 
174
 
140
 template<class T>
175
 template<class T>
141
 bool ixion::regex<T>::alternative_matcher::match(backref_stack &brstack,T const &candidate,TIndex at) {
176
 bool ixion::regex<T>::alternative_matcher::match(backref_stack &brstack,T const &candidate,TIndex at) {
Lines 143-152 Link Here
143
+  typename std::vector<matcher *>::iterator first = AltList.begin(),last = AltList.end();
178
+  typename std::vector<matcher *>::iterator first = AltList.begin(),last = AltList.end();
144
   while (first != last) {
179
   while (first != last) {
145
     if ((*first)->match(brstack,candidate,at)) {
180
     if ((*first)->match(brstack,candidate,at)) {
146
       MatchLength = 0;
181
-      MatchLength = 0;
147
@@ -548,7 +548,7 @@
182
+      this->MatchLength = 0;
183
       matcher const *object = *first;
184
       while (object != &Connector) {
185
-        MatchLength += object->getMatchLength();
186
+        this->MatchLength += object->getMatchLength();
187
         object = object->getNext();
188
         }
189
       return true;
190
@@ -546,9 +546,9 @@
191
 template<class T>
192
 void ixion::regex<T>::alternative_matcher::copy(alternative_matcher const *src) {
148
   super::copy(src);
193
   super::copy(src);
149
   Connector.setNext(Next,false);
194
-  Connector.setNext(Next,false);
195
+  Connector.setNext(this->Next,false);
150
   
196
   
151
-  FOREACH_CONST(first,src->AltList,alt_list)
197
-  FOREACH_CONST(first,src->AltList,alt_list)
152
+  FOREACH_CONST_T(first,src->AltList,alt_list)
198
+  FOREACH_CONST_T(first,src->AltList,alt_list)
Lines 162-164 Link Here
162
   backref_matcher *dupe = new backref_matcher(Backref);
208
   backref_matcher *dupe = new backref_matcher(Backref);
163
   dupe->copy(this);
209
   dupe->copy(this);
164
   return dupe;
210
   return dupe;
211
@@ -577,7 +577,7 @@
212
 template<class T>
213
 bool ixion::regex<T>::backref_matcher::match(backref_stack &brstack,T const &candidate,TIndex at) {
214
   T matchstr = brstack.get(Backref,candidate);
215
-  MatchLength = matchstr.size();
216
+  this->MatchLength = matchstr.size();
217
 
218
   if (at+matchstr.size() > candidate.size()) return false;
219
   return (T(candidate.begin()+at,candidate.begin()+at+matchstr.size()) == matchstr) &&
(-)files/patch-src::lex.xml.cc (+16 lines)
Added Link Here
1
--- src/lex.xml.cc.orig	Tue Oct 23 12:24:43 2001
2
+++ src/lex.xml.cc	Fri Dec  1 18:57:06 2006
3
@@ -24,9 +24,12 @@
4
 #ifdef __cplusplus
5
 
6
 #include <stdlib.h>
7
-#include <fstream>
8
+#include <iostream>
9
 using std::istream;
10
 using std::ostream;
11
+using std::cin;
12
+using std::cout;
13
+using std::cerr;
14
 #include <unistd.h>
15
 
16
 /* Use prototypes in function declarations. */
(-)files/patch-src::re.cc (+11 lines)
Added Link Here
1
--- src/re.cc.orig	Tue Jun 19 16:16:29 2001
2
+++ src/re.cc	Fri Dec  1 18:37:32 2006
3
@@ -26,7 +26,7 @@
4
 
5
 
6
 // Template instantiations ----------------------------------------------------
7
-template regex<string>;
8
+template class regex<string>;
9
 
10
 
11
 

Return to bug 106197