Bug#416629: src/wdm/access.o:(.debug_info+0xb64): undefined reference to `.L159'

2007-03-29 Thread Martin Michlmayr
Package: gcc-snapshot
Version: 20060326-1

I'll report to upstream when I have a small testcase.

> Automatic build of wdm_1.28-2.2 on em64t by sbuild/amd64 0.53
...
> gcc  -L./bin  -L/usr/X11R6/lib src/wdm/Greet.o src/wdm/access.o 
> src/wdm/auth.o src/wdm/choose.o src/wdm/daemon.o src/wdm/dm.o 
> src/wdm/dpylist.o src/wdm/file.o src/wdm/genauth.o src/wdm/loghelpers.o 
> src/wdm/mitauth.o src/wdm/netaddr.o src/wdm/policy.o src/wdm/protodpy.o 
> src/wdm/reset.o src/wdm/resource.o src/wdm/server.o src/wdm/session.o 
> src/wdm/socket.o src/wdm/util.o src/wdm/verify.o src/wdm/xdmcp.o -lcrypt 
> -lutil  -lwdm -lSM -lICE -lXext -lX11 -lXft -lm  -lXinerama -lWINGs -lwraster 
> -lXft -lpam -ldl  -lXmu -lXau -lXdmcp -o bin/wdm
> src/wdm/access.o:(.debug_info+0xb64): undefined reference to `.L159'
> collect2: ld returned 1 exit status

-- 
Martin Michlmayr
http://www.cyrius.com/


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Processed: Re: Bug#416629: Acknowledgement (src/wdm/access.o:(.debug_info+0xb64): undefined reference to `.L159')

2007-03-29 Thread Debian Bug Tracking System
Processing commands for [EMAIL PROTECTED]:

> forwarded 416629 http://gcc.gnu.org/PR31391
Bug#416629: src/wdm/access.o:(.debug_info+0xb64): undefined reference to `.L159'
Noted your statement that Bug has been forwarded to http://gcc.gnu.org/PR31391.

> tags 416629 + upstream
Bug#416629: src/wdm/access.o:(.debug_info+0xb64): undefined reference to `.L159'
There were no tags set.
Tags added: upstream

> --
Stopping processing here.

Please contact me if you need assistance.

Debian bug tracking system administrator
(administrator, Debian Bugs database)


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



[Bug tree-optimization/31169] Bootstrap comparison error at revision 122821

2007-03-29 Thread rth at gcc dot gnu dot org


--- Comment #33 from rth at gcc dot gnu dot org  2007-03-29 17:30 ---
I've been trying to track down this same failure on Alpha.  I can reproduce
that
reverting the third hunk allows the bootstrap to complete.  Finding what has
got
miscompiled has been very difficult.  Only two files compile differently:
fold-const.c and tree.c.

Unfortunately, a function early in fold-const.c gets compiled differently 
legitimately -- sign_bit_p actually benefits from the optimization -- and
all the functions after that differ in decl_uid numbers, which completely
obscures the rest of the changes.

I'll keep searching...


-- 

rth at gcc dot gnu dot org changed:

   What|Removed |Added

   Last reconfirmed|2007-03-14 20:03:38 |2007-03-29 17:30:45
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31169

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



[Bug tree-optimization/31169] Bootstrap comparison error at revision 122821

2007-03-29 Thread rth at gcc dot gnu dot org


--- Comment #34 from rth at gcc dot gnu dot org  2007-03-29 18:13 ---
Actually, on second thought, I don't think the sign_bit_p change is legit:

 Value ranges after VRP:

-mask_lo_1: [0, +INF]  EQUIVALENCES: { } (0 elements)
+mask_lo_1: [0x0, +INF]  EQUIVALENCES: { } (0 elements)
 lo_2: [0, +INF]  EQUIVALENCES: { } (0 elements)
 mask_hi_3: VARYING
 hi_4: VARYING
@@ -8971,7 +8971,7 @@ mask_hi_38: VARYING
 D.30338_41: [-1, 63]  EQUIVALENCES: { } (0 elements)
 lo_42: [0, +INF]  EQUIVALENCES: { } (0 elements)
 D.30339_44: [0, 64]  EQUIVALENCES: { } (0 elements)
-mask_lo_45: [0, +INF]  EQUIVALENCES: { } (0 elements)
+mask_lo_45: [0x0, +INF]  EQUIVALENCES: { } (0 elements)
 D.30340_47: [22, 22]  EQUIVALENCES: { D.30324_17 D.30324_96 } (2 elements)
 D.30341_49: VARYING
 D.30342_50: VARYING
@@ -9211,7 +9211,7 @@ sign_bit_p (exp, val)
   # hi_4 = PHI 
   # mask_hi_3 = PHI 
   # lo_2 = PHI <0(13), lo_42(14)>
-  # mask_lo_1 = PHI <0x0(13), mask_lo_45(14)>
+  # mask_lo_1 = PHI <0x0(13), 0x0(14)>
 :;
   D.30340_47 = 22;
   D.30341_49 = val_102(D)->int_cst.int_cst.high;
@@ -9221,7 +9221,7 @@ sign_bit_p (exp, val)
 :;
   D.30343_52 = 22;
   D.30344_54 = val_102(D)->int_cst.int_cst.low;
-  D.30345_55 = D.30344_54 & mask_lo_1;
+  D.30345_55 = D.30344_54;
   if (D.30345_55 == lo_2) goto ; else goto ;

 :;

The VRP change for mask_lo_1 is correct; the two values that the variable
can obtain are 0x... and 0x0fff....  But removing the BIT_AND
is incorrect, afaics.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31169

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



[Bug tree-optimization/31169] Bootstrap comparison error at revision 122821

2007-03-29 Thread rth at gcc dot gnu dot org


--- Comment #35 from rth at gcc dot gnu dot org  2007-03-29 18:21 ---
With some sed help, one can see that fold_binary is completely ruined:

-  mhi = 0x0 >> 128 - width;
-  if ((~(hi2 | hi1) & mhi) == 0) goto ; else goto ;
-
-:;
-  mlo = 0x0;
+  mhi = 0;
   goto  ();

Incorrect folding is surely what causes ivopts to do bad things, and bad
loop opts is the visible miscompilation problem in stage3.  Probably you
can extract sign_bit_p from any target's preprocessing and debug the 
problem.  If that's not true, I can go back and do it.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31169

--- You are receiving this mail because: ---
You are on the CC list for the bug, or are watching someone who is.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#416704: reportbug-g++-20070329-12960-Tq7l2a

2007-03-29 Thread guido schillaci

Subject: ../sysdeps/i386/elf/start.S:115: undefined reference to `main'
Package: g++-4.1
Version: 4.1.1-21
Severity: serious
Justification: no longer builds from source

*** Please type your report below this line ***
I would compile a cpp source but when compiling with

g++ -o VelocityModel VelocityModel.cc

i receive this error

/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../lib/crt1.o: In function 
`_start':

../sysdeps/i386/elf/start.S:115: undefined reference to `main'
collect2: ld returned 1 exit status


then there is the file:
VelocityModel.cc


--

// Esercizio 2: motion models
//
// Classe VelocityModel
//
// Implementa gli algoritmi per il modello di velocità
//
//
// Istruzioni compilazione:
// g++ -o VelocityModel VelocityModel.cc
//


#include 
#include 
#include 
#include 


using namespace std;
class VelocityModel {

public:

   //impostare a1, a2, a3, a4, a5, a6
   //sono i parametri di rumore del moto
   double a1;
   double a2;
   double a3;
   double a4;
   double a5;
   double a6;

   //quanto è deltaT (tempo)
   double dT;

   //costruttore semplice
   VelocityModel()
   {
   }

   //costruttore che riceve come parametri di ingresso i valori di a e di 
deltaT
   VelocityModel(double aa1,double aa2,double aa3,double aa4,double 
aa5,double aa6, double ddT )

   {
a1=aa1;
a2=aa2;
a3=aa3;
a4=aa4;
a5=aa5;
a6=aa6;
dT=ddT;
   }

   ~VelocityModel( )
   {
   }
   //algoritmo motion_model_velocity ( pg.123 tabella 5.1)
   double algoritmo(double ipotPose[], double control[], double initPose[] 
)

   {
double mu= 0.5 * ( ((initPose[1]-ipotPose[1])*cos(initPose[3])) +
((initPose[2]-ipotPose[2])*sin(initPose[3])) ) /
 ( ((initPose[2]-ipotPose[2])*cos(initPose[3])) -
((initPose[1]-ipotPose[1])*sin(initPose[3])) );

double xstar= 0.5*(initPose[1]+ipotPose[1]) + 
mu*(initPose[2]-ipotPose[2]);

double ystar= 0.5*(initPose[2]+ipotPose[2]) + 
mu*(ipotPose[1]-initPose[1]);

   double rstar= sqrt( (initPose[1]-xstar)*(initPose[1]-xstar) 
+(initPose[2]-ystar)*(initPose[2]-ystar)

);

	double dTeta= atan2( (ipotPose[2]-ystar) , (ipotPose[1]-xstar) ) - atan2( 
(initPose[2]-ystar)

,(initPose[1]-xstar) );

double vC= dTeta*rstar/dT;

   double omegaC= dTeta/dT;

double gammaC= ((ipotPose[3] - initPose[3]) * dT) - omegaC;

	return ( prob( (control[1] - vC), (a1* abs(control[1]) + a2*abs(control[2]) 
) ) *
		 prob( (control[2] - omegaC), (a3* abs(control[1]) + a4*abs(control[2]) ) 
) *
		 prob( gammaC, (a5* abs(control[1]) + a6*abs(control[2]) ) )   
 );


   }

   //algoritmo di supporto al motion_model_velocity (pg. 123 tabella 5.2)
   //la funzione calcola la probabilità del suo argomento "a" sotto una 
distribuzione centrata

   //a zero con deviazione standard "b"
   double prob(double a, double b)
   {
//prob_normal_distribution
return ( (1/sqrt(2*M_PI*b*b))* exp(-0.5*a*a*(1/b)*(1/b)));

//prob_triangular_distribution
// return ( max( 0 , ( (1/(sqrt(6)*b)) - (abs(a)/(6*b*b)) ) ) );
   }



   //algoritmo sample_motion_model_velocity (pg.124, tabella 5.3)
   //la funzione  ritorna un array.
   //per prendere il valore dall'esterno: inizializzare il vettore come 
puntatore

   //
   //esempio:
   //
   // double *vettore;
   // vettore=sample_algoritmo(control, initPose);
   double* sample_algoritmo(double control[], double initPose[])
   {
static double ipotPose[3];
double vC= control[1] + sample(a1*abs(control[1]) + a2*abs(control[2]));
	double omegaC= control[2] + sample(a3*abs(control[1]) + 
a4*abs(control[2]));

double gammaC= sample(a5*abs(control[1]) + a6*abs(control[2]));
	ipotPose[1]= initPose[1] - (vC/omegaC)*sin(initPose[3]) + 
(vC/omegaC)*sin(initPose[3] + omegaC*dT);
	ipotPose[2]= initPose[2] + (vC/omegaC)*cos(initPose[3]) - 
(vC/omegaC)*cos(initPose[3] + omegaC*dT);

ipotPose[3]= initPose[3] + omegaC*dT + gammaC*dT;

return ipotPose;
   }

   //algoritmo di supporto al sample_motion_model_velocity (pg.124 tabella 
5.4)
   //la funzione genera un campione random da una distribuzione centrata a 
zero con deviazione standard "b"

   double sample(double b)
   {
//--
//sample normal distribution
//--
double ran;
double somma=0;

// inizializza random seed:
srand ( time(NULL) );

// genera numero:
ran = (-b) + rand() * (b - (-b)) / RAND_MAX;
//  ran = rand() % b + (-b);

for (int i=0; i<12; i++)
{
somma=somma+ran;
ran = (-b) + rand() * (b - (-b)) / RAND_MAX;
}
return (0.5*somma);


//--
//sample triangular distribution
//--
/*
 

Bug#416705: ../sysdeps/i386/elf/start.S:115: undefined reference to `main'

2007-03-29 Thread Guido Schillaci
Package: g++-4.1
Version: 4.1.1-21
Severity: serious
Justification: no longer builds from source

I would compile a cpp source but when compiling with

g++ -o VelocityModel VelocityModel.cc

i receive this error

/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../lib/crt1.o: In function `_start':
.../sysdeps/i386/elf/start.S:115: undefined reference to `main'
collect2: ld returned 1 exit status


then there is the file:
VelocityModel.cc


--

// Esercizio 2: motion models
//
// Classe VelocityModel
//
// Implementa gli algoritmi per il modello di velocità
//
//
// Istruzioni compilazione:
// g++ -o VelocityModel VelocityModel.cc 
//


#include 
#include  
#include 
#include 


using namespace std; 
class VelocityModel {
 
public:

//impostare a1, a2, a3, a4, a5, a6
//sono i parametri di rumore del moto
double a1;
double a2;
double a3;
double a4;
double a5;
double a6;

//quanto è deltaT (tempo)
double dT;

//costruttore semplice
VelocityModel()
{
}   

//costruttore che riceve come parametri di ingresso i valori di a e di 
deltaT
VelocityModel(double aa1,double aa2,double aa3,double aa4,double aa5,double 
aa6, double ddT ) 
{
a1=aa1;
a2=aa2;
a3=aa3;
a4=aa4;
a5=aa5;
a6=aa6;
dT=ddT;
}
 
~VelocityModel( )
{
}
//algoritmo motion_model_velocity ( pg.123 tabella 5.1)
double algoritmo(double ipotPose[], double control[], double initPose[] ) 
{
double mu= 0.5 * ( ((initPose[1]-ipotPose[1])*cos(initPose[3])) + 
((initPose[2]-ipotPose[2])*sin(initPose[3])) ) /
  ( ((initPose[2]-ipotPose[2])*cos(initPose[3])) - 
((initPose[1]-ipotPose[1])*sin(initPose[3])) ); 

double xstar= 0.5*(initPose[1]+ipotPose[1]) + 
mu*(initPose[2]-ipotPose[2]);

double ystar= 0.5*(initPose[2]+ipotPose[2]) + 
mu*(ipotPose[1]-initPose[1]);

double rstar= sqrt( (initPose[1]-xstar)*(initPose[1]-xstar) 
+(initPose[2]-ystar)*(initPose[2]-ystar) 
);

double dTeta= atan2( (ipotPose[2]-ystar) , (ipotPose[1]-xstar) ) - 
atan2( (initPose[2]-ystar) 
,(initPose[1]-xstar) );

double vC= dTeta*rstar/dT; 

double omegaC= dTeta/dT; 

double gammaC= ((ipotPose[3] - initPose[3]) * dT) - omegaC;  

return ( prob( (control[1] - vC), (a1* abs(control[1]) + 
a2*abs(control[2]) ) ) *
 prob( (control[2] - omegaC), (a3* abs(control[1]) + 
a4*abs(control[2]) ) ) *
 prob( gammaC, (a5* abs(control[1]) + a6*abs(control[2]) ) )
);

}

//algoritmo di supporto al motion_model_velocity (pg. 123 tabella 5.2)
//la funzione calcola la probabilità del suo argomento "a" sotto una 
distribuzione centrata
//a zero con deviazione standard "b"
double prob(double a, double b)
{
//prob_normal_distribution
return ( (1/sqrt(2*M_PI*b*b))* exp(-0.5*a*a*(1/b)*(1/b)));

//prob_triangular_distribution
// return ( max( 0 , ( (1/(sqrt(6)*b)) - (abs(a)/(6*b*b)) ) ) );
}



//algoritmo sample_motion_model_velocity (pg.124, tabella 5.3) 
//la funzione  ritorna un array. 
//per prendere il valore dall'esterno: inizializzare il vettore come 
puntatore 
//
//esempio:
//
// double *vettore;
// vettore=sample_algoritmo(control, initPose);
double* sample_algoritmo(double control[], double initPose[])
{
static double ipotPose[3];
double vC= control[1] + sample(a1*abs(control[1]) + a2*abs(control[2]));
double omegaC= control[2] + sample(a3*abs(control[1]) + 
a4*abs(control[2]));
double gammaC= sample(a5*abs(control[1]) + a6*abs(control[2]));
ipotPose[1]= initPose[1] - (vC/omegaC)*sin(initPose[3]) + 
(vC/omegaC)*sin(initPose[3] + omegaC*dT); 
ipotPose[2]= initPose[2] + (vC/omegaC)*cos(initPose[3]) - 
(vC/omegaC)*cos(initPose[3] + omegaC*dT); 
ipotPose[3]= initPose[3] + omegaC*dT + gammaC*dT; 

return ipotPose;
}

//algoritmo di supporto al sample_motion_model_velocity (pg.124 tabella 5.4)
//la funzione genera un campione random da una distribuzione centrata a 
zero con deviazione standard "b"
double sample(double b)
{
//--
//sample normal distribution
//--
double ran;
double somma=0;

// inizializza random seed:
srand ( time(NULL) );

// genera numero: 
ran = (-b) + rand() * (b - (-b)) / RAND_MAX;
//  ran = rand() % b + (-b);

for (int i=0; i<12; i++)
{
somma=somma+ran;
ran = (-b) + rand() * (b - (-b)) / RAND_MAX;
}   
return (0.5*somma);


//--
//sample triangular distribution
//

Welcome to Al-Manahel Newsletter List

2007-03-29 Thread munir

The subscription of the email address: 

[EMAIL PROTECTED]

To the mailing list: 

Al-Manahel Newsletter List

is all set. Thanks for subscribing! 

Date of this subscription: Thu Mar 29 15:20:47 2007

Please save this email message for future reference. 

---

You may automatically unsubscribe from this list at any time by 
visiting the following URL:



If the above URL is inoperable, make sure that you have copied the 
entire address. Some mail readers will wrap a long URL and thus break
this automatic unsubscribe mechanism. 

You may also change your subscription by visiting this list's main screen: 



If you're still having trouble, please contact the list owner at: 



The following physical address is associated with this mailing list: 



- 


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#416705: marked as done (../sysdeps/i386/elf/start.S:115: undefined reference to `main')

2007-03-29 Thread Debian Bug Tracking System
Your message dated Thu, 29 Mar 2007 14:57:54 -0700
with message-id <[EMAIL PROTECTED]>
and subject line Bug#416705: ../sysdeps/i386/elf/start.S:115: undefined 
reference to `main'
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---
Package: g++-4.1
Version: 4.1.1-21
Severity: serious
Justification: no longer builds from source

I would compile a cpp source but when compiling with

g++ -o VelocityModel VelocityModel.cc

i receive this error

/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../lib/crt1.o: In function `_start':
.../sysdeps/i386/elf/start.S:115: undefined reference to `main'
collect2: ld returned 1 exit status


then there is the file:
VelocityModel.cc


--

// Esercizio 2: motion models
//
// Classe VelocityModel
//
// Implementa gli algoritmi per il modello di velocità
//
//
// Istruzioni compilazione:
// g++ -o VelocityModel VelocityModel.cc 
//


#include 
#include  
#include 
#include 


using namespace std; 
class VelocityModel {
 
public:

//impostare a1, a2, a3, a4, a5, a6
//sono i parametri di rumore del moto
double a1;
double a2;
double a3;
double a4;
double a5;
double a6;

//quanto è deltaT (tempo)
double dT;

//costruttore semplice
VelocityModel()
{
}   

//costruttore che riceve come parametri di ingresso i valori di a e di 
deltaT
VelocityModel(double aa1,double aa2,double aa3,double aa4,double aa5,double 
aa6, double ddT ) 
{
a1=aa1;
a2=aa2;
a3=aa3;
a4=aa4;
a5=aa5;
a6=aa6;
dT=ddT;
}
 
~VelocityModel( )
{
}
//algoritmo motion_model_velocity ( pg.123 tabella 5.1)
double algoritmo(double ipotPose[], double control[], double initPose[] ) 
{
double mu= 0.5 * ( ((initPose[1]-ipotPose[1])*cos(initPose[3])) + 
((initPose[2]-ipotPose[2])*sin(initPose[3])) ) /
  ( ((initPose[2]-ipotPose[2])*cos(initPose[3])) - 
((initPose[1]-ipotPose[1])*sin(initPose[3])) ); 

double xstar= 0.5*(initPose[1]+ipotPose[1]) + 
mu*(initPose[2]-ipotPose[2]);

double ystar= 0.5*(initPose[2]+ipotPose[2]) + 
mu*(ipotPose[1]-initPose[1]);

double rstar= sqrt( (initPose[1]-xstar)*(initPose[1]-xstar) 
+(initPose[2]-ystar)*(initPose[2]-ystar) 
);

double dTeta= atan2( (ipotPose[2]-ystar) , (ipotPose[1]-xstar) ) - 
atan2( (initPose[2]-ystar) 
,(initPose[1]-xstar) );

double vC= dTeta*rstar/dT; 

double omegaC= dTeta/dT; 

double gammaC= ((ipotPose[3] - initPose[3]) * dT) - omegaC;  

return ( prob( (control[1] - vC), (a1* abs(control[1]) + 
a2*abs(control[2]) ) ) *
 prob( (control[2] - omegaC), (a3* abs(control[1]) + 
a4*abs(control[2]) ) ) *
 prob( gammaC, (a5* abs(control[1]) + a6*abs(control[2]) ) )
);

}

//algoritmo di supporto al motion_model_velocity (pg. 123 tabella 5.2)
//la funzione calcola la probabilità del suo argomento "a" sotto una 
distribuzione centrata
//a zero con deviazione standard "b"
double prob(double a, double b)
{
//prob_normal_distribution
return ( (1/sqrt(2*M_PI*b*b))* exp(-0.5*a*a*(1/b)*(1/b)));

//prob_triangular_distribution
// return ( max( 0 , ( (1/(sqrt(6)*b)) - (abs(a)/(6*b*b)) ) ) );
}



//algoritmo sample_motion_model_velocity (pg.124, tabella 5.3) 
//la funzione  ritorna un array. 
//per prendere il valore dall'esterno: inizializzare il vettore come 
puntatore 
//
//esempio:
//
// double *vettore;
// vettore=sample_algoritmo(control, initPose);
double* sample_algoritmo(double control[], double initPose[])
{
static double ipotPose[3];
double vC= control[1] + sample(a1*abs(control[1]) + a2*abs(control[2]));
double omegaC= control[2] + sample(a3*abs(control[1]) + 
a4*abs(control[2]));
double gammaC= sample(a5*abs(control[1]) + a6*abs(control[2]));
ipotPose[1]= initPose[1] - (vC/omegaC)*sin(initPose[3]) + 
(vC/omegaC)*sin(initPose[3] + omegaC*dT); 
ipotPose[2]= initPose[2] + (vC/omegaC)*cos(initPose[3]) - 
(vC/omegaC)*cos(initPose[3] + omegaC*dT); 
ipotPose[3]= initPose[3] + omegaC*dT + gammaC*dT; 

return ipotPose;
}

//algoritmo di supporto al sample_motion_model_velocity (pg.124 tabella 5.4)
//la funzione genera un campione random da una distribuzione centrata 

Bug#416704: marked as done (reportbug-g++-20070329-12960-Tq7l2a)

2007-03-29 Thread Debian Bug Tracking System
Your message dated Thu, 29 Mar 2007 14:57:54 -0700
with message-id <[EMAIL PROTECTED]>
and subject line Bug#416705: ../sysdeps/i386/elf/start.S:115: undefined 
reference to `main'
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--- Begin Message ---

Subject: ../sysdeps/i386/elf/start.S:115: undefined reference to `main'
Package: g++-4.1
Version: 4.1.1-21
Severity: serious
Justification: no longer builds from source

*** Please type your report below this line ***
I would compile a cpp source but when compiling with

g++ -o VelocityModel VelocityModel.cc

i receive this error

/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../lib/crt1.o: In function 
`_start':

../sysdeps/i386/elf/start.S:115: undefined reference to `main'
collect2: ld returned 1 exit status


then there is the file:
VelocityModel.cc


--

// Esercizio 2: motion models
//
// Classe VelocityModel
//
// Implementa gli algoritmi per il modello di velocità
//
//
// Istruzioni compilazione:
// g++ -o VelocityModel VelocityModel.cc
//


#include 
#include 
#include 
#include 


using namespace std;
class VelocityModel {

public:

   //impostare a1, a2, a3, a4, a5, a6
   //sono i parametri di rumore del moto
   double a1;
   double a2;
   double a3;
   double a4;
   double a5;
   double a6;

   //quanto è deltaT (tempo)
   double dT;

   //costruttore semplice
   VelocityModel()
   {
   }

   //costruttore che riceve come parametri di ingresso i valori di a e di 
deltaT
   VelocityModel(double aa1,double aa2,double aa3,double aa4,double 
aa5,double aa6, double ddT )

   {
a1=aa1;
a2=aa2;
a3=aa3;
a4=aa4;
a5=aa5;
a6=aa6;
dT=ddT;
   }

   ~VelocityModel( )
   {
   }
   //algoritmo motion_model_velocity ( pg.123 tabella 5.1)
   double algoritmo(double ipotPose[], double control[], double initPose[] 
)

   {
double mu= 0.5 * ( ((initPose[1]-ipotPose[1])*cos(initPose[3])) +
((initPose[2]-ipotPose[2])*sin(initPose[3])) ) /
 ( ((initPose[2]-ipotPose[2])*cos(initPose[3])) -
((initPose[1]-ipotPose[1])*sin(initPose[3])) );

double xstar= 0.5*(initPose[1]+ipotPose[1]) + 
mu*(initPose[2]-ipotPose[2]);

double ystar= 0.5*(initPose[2]+ipotPose[2]) + 
mu*(ipotPose[1]-initPose[1]);

   double rstar= sqrt( (initPose[1]-xstar)*(initPose[1]-xstar) 
+(initPose[2]-ystar)*(initPose[2]-ystar)

);

	double dTeta= atan2( (ipotPose[2]-ystar) , (ipotPose[1]-xstar) ) - atan2( 
(initPose[2]-ystar)

,(initPose[1]-xstar) );

double vC= dTeta*rstar/dT;

   double omegaC= dTeta/dT;

double gammaC= ((ipotPose[3] - initPose[3]) * dT) - omegaC;

	return ( prob( (control[1] - vC), (a1* abs(control[1]) + a2*abs(control[2]) 
) ) *
		 prob( (control[2] - omegaC), (a3* abs(control[1]) + a4*abs(control[2]) ) 
) *
		 prob( gammaC, (a5* abs(control[1]) + a6*abs(control[2]) ) )   
 );


   }

   //algoritmo di supporto al motion_model_velocity (pg. 123 tabella 5.2)
   //la funzione calcola la probabilità del suo argomento "a" sotto una 
distribuzione centrata

   //a zero con deviazione standard "b"
   double prob(double a, double b)
   {
//prob_normal_distribution
return ( (1/sqrt(2*M_PI*b*b))* exp(-0.5*a*a*(1/b)*(1/b)));

//prob_triangular_distribution
// return ( max( 0 , ( (1/(sqrt(6)*b)) - (abs(a)/(6*b*b)) ) ) );
   }



   //algoritmo sample_motion_model_velocity (pg.124, tabella 5.3)
   //la funzione  ritorna un array.
   //per prendere il valore dall'esterno: inizializzare il vettore come 
puntatore

   //
   //esempio:
   //
   // double *vettore;
   // vettore=sample_algoritmo(control, initPose);
   double* sample_algoritmo(double control[], double initPose[])
   {
static double ipotPose[3];
double vC= control[1] + sample(a1*abs(control[1]) + a2*abs(control[2]));
	double omegaC= control[2] + sample(a3*abs(control[1]) + 
a4*abs(control[2]));

double gammaC= sample(a5*abs(control[1]) + a6*abs(control[2]));
	ipotPose[1]= initPose[1] - (vC/omegaC)*sin(initPose[3]) + 
(vC/omegaC)*sin(initPose[3] + omegaC*dT);
	ipotPose[2]= initPose[2] + (vC/omegaC)*cos(initPose[3]) - 
(vC/omegaC)*cos(initPose[3] + omegaC*dT);

ipotPose[3]= initPose[3] + omegaC*dT + gammaC*dT;

return ipotPose;
   }

   //algoritmo di supporto al sample_motion_model_velocity (pg.124 tabella 
5.4)
   //la funzione genera un campione random da una distribuzione centrata a 
zero co