QB64.org Forum

Active Forums => QB64 Discussion => Topic started by: krovit on September 20, 2021, 03:52:18 am

Title: compilation error ??
Post by: krovit on September 20, 2021, 03:52:18 am
Good morning or good evening or good night...

On win10 no problem, it seems.
On win7 the compilation ends with a fatal error.

I switched from version 1.51 to 1.6 (qb64_2021-09-20-01-33-33_e30f7a1_win-x64.7z)


Any suggestions?


Title: Re: compilation error ??
Post by: SMcNeill on September 20, 2021, 04:29:42 am
@SpriggsySpriggs will need to be the one to ask about the problem; it’s showing as pointing to something in his pipecom.h library.  I’d imagine he’d appreciate it if you could share the whole program with him, so he could try and reproduce the glitch to fix it,  it’s hard to debug a program without having the code for that program.
Title: Re: compilation error ??
Post by: RhoSigma on September 20, 2021, 04:32:14 am
It's a pipecom specific error, so @SpriggsySpriggs will probably catch your problem. Seems he's using an undeclared type/class in pipecom, which should be easy for him to fix.
Title: Re: compilation error ??
Post by: krovit on September 20, 2021, 05:18:03 am
Thank You...

Code: QB64: [Select]
  1. common shared winver%, utente$
  2.  
  3. DECLARE LIBRARY ".\pipecom"
  4.     FUNCTION pipecom$ (cmd AS STRING)
  5. ver = MID$(pipecom("ver"), 2)
  6.  
  7. k$=""
  8. for f = 1 to len(ver)
  9.         if instr( "1234567890.", mid$(ver, f, 1) ) <> 0 then k$ = k$ + mid$(ver,f,1)
  10. if instr(k$,"6.1.76") > 0 then
  11.    winver = 7
  12. elseif instr(k$,"6.2.") > 0 or instr(k$,"6.3.") > 0 then
  13.    winver = 8
  14. elseif instr(k$,"10.") > 0 then
  15.    winver = 10
  16.  
  17. if winver = 10 then
  18.         for f = instr(_DIR$(""), "User") to len(_dir$(""))
  19.                 if mid$(_DIR$(""), f, 1) ="\" then exit for
  20.         next f
  21.         utente$ = mid$(_DIR$(""), f+1, instr(mid$(_DIR$(""),f+1), "\") - 1)
  22. elseif winver = 7 then
  23.         for f=instr(_DIR$(""), "User") to len(_dir$(""))
  24.                 if mid$(_DIR$(""), f, 1) ="\" then exit for
  25.         next f
  26.         utente$ = mid$(_DIR$(""), f + 1,instr(mid$(_DIR$(""),f+1), "\") - 1)
  27.  
  28.  
  29. ? ver
  30.  
  31.  
  32.  
  33.  
  34. '------------------------------------------------------------------------------------------------------
  35. '6.0.6000       Windows Vista
  36. '6.0.6001       Windows Vista with Service Pack 1 'or Windows Server 2008
  37. '6.1.7600       Windows 7 'or Windows Server 2008 R2
  38. '6.1.7601       Windows 7 with Service Pack 1 'or Windows Server 2008 R2 with Service Pack 1
  39. '6.2.9200       Windows 8 'or Windows Server 2012
  40. '6.3.9200       Windows 8.1 'or Windows Server 2012 R2
  41. '6.3.9600       Windows 8.1 with Update 1
  42. '10.0.10240     Windows 10 Version 1507
  43. '10.0.10586     Windows 10 Version 1511 (November Update)
  44. '10.0.14393     Windows 10 Version 1607 (Anniversary Update) 'or Windows Server 2016
  45. '10.0.15063     Windows 10 Version 1703 (Creators Update)
  46. '10.0.16299     Windows 10 Version 1709 (Fall Creators Update)
  47. '10.0.17134     Windows 10 Version 1803 (April 2018 Update)
  48. '10.0.17763     Windows 10 Version 1809 (October 2018 Update) 'or Windows Server 2019
  49. '10.0.18362     Windows 10 Version 1903 (May 2019 Update)
  50. '10.0.18363     Windows 10 Version 1909 (November 2019 Update)
  51. '10.0.19041     Windows 10 Version 2004 (May 2020 Update)
  52. 'Note that there is normally no need to specify the build numbers (i.e., you may simply use "6.2" for Windows 8).
  53. '------------------------------------------------------------------------------------------------------
  54.  
  55.  
Title: Re: compilation error ??
Post by: FellippeHeitor on September 20, 2021, 05:27:21 am
Try adding std:: before string in the header file - there has been a change regarding c++ standard library in v1.6.

Spriggsy did change pipecom so it wouldn’t rely on a c++ header - it seems you’re using an outdated version of his code anyway. I’d recommend getting the latest version of his library (search for pipecom here in the forum).
Title: Re: compilation error ??
Post by: krovit on September 20, 2021, 05:42:35 am
Thank you Philippe...

adding   STD::   in the head to pipecom.h the problem seems solved.

I will still look for the updated version of pipecom.h as you suggested

Title: Re: compilation error ??
Post by: SpriggsySpriggs on September 20, 2021, 07:42:35 am
That isn't my latest version of pipecom. I do not support the header version anymore. You should download the BAS version from the library.
Title: Re: compilation error ??
Post by: SpriggsySpriggs on September 20, 2021, 10:07:35 am
You can find my latest and supported version of pipecom here: https://www.qb64.org/forum/index.php?topic=4095.0 (https://www.qb64.org/forum/index.php?topic=4095.0)
Title: Re: compilation error ??
Post by: krovit on September 20, 2021, 12:47:54 pm
ok, done! Thank you