help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: RE: "undefined reference" error message when using mkoctfile to crea


From: Tatsuro MATSUOKA
Subject: Re: RE: "undefined reference" error message when using mkoctfile to create oct file
Date: Thu, 23 Feb 2017 12:01:42 +0900 (JST)

----- Original Message -----

> From: Tatsuro MATSUOKA 
> To: tmacchant Yan Zhang  "help-octave
> Cc: 
> Date: 2017/2/23, Thu 10:37
> Subject: Re: RE: "undefined reference" error message when using mkoctfile to 
> create oct file
> 
> ----- Original Message -----
> 
>>  From: Tatsuro MATSUOKA 
>>  To: Yan Zhang ; "help-octave> Cc: 
>>  Date: 2017/2/22, Wed 13:54
>>  Subject: Re: RE: "undefined reference" error message when using 
> mkoctfile to create oct file
>> 
>> 
>> 
>> 
>> 
>>  ----- Original Message -----
>>>   From: Yan Zhang 
>>>   To: "help-octave
>>>   Cc: 
>>>   Date: 2017/2/22, Wed 11:15
>>>   Subject: RE: RE: "undefined reference" error message when 
> using 
>>  mkoctfile to create oct file
>>> 
>>>  T hanks a lot for the kind help. I tried the dlltool and pexports and 
>>>   successfully got a new lib file which I renamed as 
>>  "usbdllnew.lib". 
>>>   Unfortunately, I still couldn't make it work. Following are the 
>>  messages I 
>>>   got:
>>> 
>>> 
>>>   -----------------------------------------------------
>>>>>    mkoctfile PowerMeter.cc -L. -lusbdllnew
>>>   PowerMeter.o: In function `Z12CloseDevicesv':
>>> 
>> 
> C:\Users\yan\Desktop\TestCam_Project\Oct_Src\cc/PowerMeter.cc:20: 
> 
>> 
>>>   undefined reference to address@hidden'
>>>   PowerMeter.o: In function `Z11OpenDevicesi':
>>> 
>> 
> C:\Users\yan\Desktop\TestCam_Project\Oct_Src\cc/PowerMeter.cc:30: 
> 
>> 
>>>   undefined reference to address@hidden'
>>> 
>> 
> C:\Users\yan\Desktop\TestCam_Project\Oct_Src\cc/PowerMeter.cc:31: 
> 
>> 
>>>   undefined reference to address@hidden'
>>>   PowerMeter.o: In function `Z4ReadiPciPm':
>>> 
>> 
> C:\Users\yan\Desktop\TestCam_Project\Oct_Src\cc/PowerMeter.cc:41: 
> 
>> 
>>>   undefined reference to address@hidden'
>>>   PowerMeter.o: In function `Z5WriteiPc':
>>> 
>> 
> C:\Users\yan\Desktop\TestCam_Project\Oct_Src\cc/PowerMeter.cc:67: 
> 
>> 
>>>   undefined reference to address@hidden'
>>>   collect2.exe: error: ld returned 1 exit status
>>>   warning: mkoctfile exited with failure status
>>>   warning: called from
>>>       mkoctfile at line 171 column 5
>>>   -----------------------------------------------------
>>> 
>>> 
>>>   Thanks,
>>> 
>>>   Yan 
>>>   
> 
> 
> Hello
> 
> The below might be related to your trouble.
> 
> http://stackoverflow.com/questions/8063842/mingw32-g-and-stdcall-suffix
> 
> 
> Tatsuro


Sorry frequently posting.

Seeing header file (NewpDll.h) in the original post.  _stdcall
 is used.

This gives a object file PowerMeter.o with symbols added with @(bytes number of 
arguments).
Perhaps symbols added with @(bytes number of arguments) does not exist in 
usbdll.dll and 
error like 
undefined reference to address@hidden'
at link stage.

If you get gendef.exe in the way my previous post, 
please execute

gendef - usbdll.dll

and see if symbol decorated with "@n" (n is number of byte of arguments).
As reference, it will be grateful you paste the results in the reply.

Tatsuro



reply via email to

[Prev in Thread] Current Thread [Next in Thread]