aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: Problem when compiling in windows...  (Read 9200 times)

iZeus83

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 9
Problem when compiling in windows...
« on: October 18, 2014, 08:31:27 PM »

Hi.

I was trying to compile aMule for windows from the latest SVN version, the problem is when I load the project named "aMule-MSVC12E-ExtLibs30" then I see this log message and can't continue to compile the project:

Code: [Select]
1>LINK : fatal error LNK1181: cannot open input file '............wxWidgets30libvc_libwxmsw30ud_media.lib'
1>C:Program Files (x86)MSBuildMicrosoft.Cppv4.0V120Microsoft.CppCommon.targets(132,5): error MSB3073: The command "if not exist ....Debug30 mkdir ....Debug30
1>C:Program Files (x86)MSBuildMicrosoft.Cppv4.0V120Microsoft.CppCommon.targets(132,5): error MSB3073: lib /LTCG /out:....Debug30libext.lib "............wxWidgets30libvc_libwxmsw30ud_media.lib" "............wxWidgets30libvc_libwxjpegd.lib" "............wxWidgets30libvc_libwxmsw30ud_adv.lib" "............wxWidgets30libvc_libwxregexud.lib" "............wxWidgets30libvc_libwxmsw30ud_richtext.lib" "............wxWidgets30libvc_libwxzlibd.lib" "............wxWidgets30libvc_libwxbase30ud.lib" "............wxWidgets30libvc_libwxmsw30ud_qa.lib" "............wxWidgets30libvc_libwxbase30ud_xml.lib" "............cryptoppwin32outputdebugcryptlib.lib" "............wxWidgets30libvc_libwxtiffd.lib" "............wxWidgets30libvc_libwxbase30ud_net.lib" "............wxWidgets30libvc_libwxmsw30ud_core.lib" "............wxWidgets30libvc_libwxmsw30ud_gl.lib" "............wxWidgets30libvc_libwxpngd.lib" "............wxWidgets30libvc_libwxmsw30ud_xrc.lib" "............wxWidgets30libvc_libwxexpatd.lib" "............wxWidgets30libvc_libwxmsw30ud_html.lib" "............wxWidgets30libvc_libwxmsw30ud_aui.lib"
1>C:Program Files (x86)MSBuildMicrosoft.Cppv4.0V120Microsoft.CppCommon.targets(132,5): error MSB3073:
1>C:Program Files (x86)MSBuildMicrosoft.Cppv4.0V120Microsoft.CppCommon.targets(132,5): error MSB3073: :VCEnd" exited with code 1181.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

Furthermore, first I build widgets 3.0 with no errors, so I don't know what's wrong.

Thanks...
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: Problem when compiling in windows...
« Reply #1 on: October 19, 2014, 12:48:31 PM »

Current tested version is
- aMule SVN 10851 (or later)
- wxWidgets 3.02
- Visual Studio Express 2013

Make sure wx is in the "somewhere\wxwidgets30" directory parallel to "somewhere\amuledir" as described in the wiki.
There is no need to prebuild wx. Unpack wx to an empty dir and just build the aMule-MSVC12E-ExtLibs30.sln .
Debug works out of the box, for release builds you have to switch the code generation of the wx projects from "Multi-threaded DLL /MD" to "Multi-threaded /MT".
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

iZeus83

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 9
Re: Problem when compiling in windows...
« Reply #2 on: October 19, 2014, 10:33:40 PM »

Thank you Stu for the guide.

After follow you guide it seeems that cryptlib is something wrong. I used debug build but I think the problem is in another place.

Here's the log file.

Code: [Select]
1>------ Build started: Project: cryptlib, Configuration: Debug Win32 ------
1>  pch.cpp
1>  3way.cpp
1>  adler32.cpp
1>  algebra.cpp
1>  algparam.cpp
1>  arc4.cpp
1>  asn.cpp
1>  authenc.cpp
1>  base32.cpp
1>  base64.cpp
1>  basecode.cpp
1>  bfinit.cpp
1>  blowfish.cpp
1>  blumshub.cpp
1>  camellia.cpp
1>  cast.cpp
1>  casts.cpp
1>  cbcmac.cpp
1>  ccm.cpp
1>  channels.cpp
1>  cmac.cpp
1>  Generating Code...
1>  Compiling...
1>  cpu.cpp
1>  crc.cpp
1>  cryptlib.cpp
1>  default.cpp
1>  des.cpp
1>  dessp.cpp
1>  dh.cpp
1>  dh2.cpp
1>  dsa.cpp
1>  eax.cpp
1>  ec2n.cpp
1>  eccrypto.cpp
1>  ecp.cpp
1>  elgamal.cpp
1>  emsa2.cpp
1>  eprecomp.cpp
1>  esign.cpp
1>  files.cpp
1>  filters.cpp
1>  fips140.cpp
1>  Generating Code...
1>  Compiling...
1>  fipstest.cpp
1>  gcm.cpp
1>  gf256.cpp
1>  gf2n.cpp
1>  gf2_32.cpp
1>  gfpcrypt.cpp
1>  gost.cpp
1>  gzip.cpp
1>  hex.cpp
1>  hmac.cpp
1>  hrtimer.cpp
1>  ida.cpp
1>  idea.cpp
1>  integer.cpp
1>  luc.cpp
1>  mars.cpp
1>  marss.cpp
1>  md2.cpp
1>  md4.cpp
1>  md5.cpp
1>  Generating Code...
1>  Compiling...
1>  misc.cpp
1>  modes.cpp
1>  mqueue.cpp
1>  mqv.cpp
1>  nbtheory.cpp
1>  network.cpp
1>  oaep.cpp
1>  osrng.cpp
1>  panama.cpp
1>  pkcspad.cpp
1>  polynomi.cpp
1>  pssr.cpp
1>  pubkey.cpp
1>  queue.cpp
1>  rabin.cpp
1>  randpool.cpp
1>  rc2.cpp
1>  rc5.cpp
1>  rc6.cpp
1>  rdtables.cpp
1>  Generating Code...
1>  Compiling...
1>  rijndael.cpp
1>  ripemd.cpp
1>  rng.cpp
1>  rsa.cpp
1>  rw.cpp
1>  safer.cpp
1>  salsa.cpp
1>  seal.cpp
1>  seed.cpp
1>  serpent.cpp
1>  sha.cpp
1>  sha3.cpp
1>  shacal2.cpp
1>  shark.cpp
1>  sharkbox.cpp
1>  simple.cpp
1>  skipjack.cpp
1>  socketft.cpp
1>socketft.cpp(102): warning C4996: 'inet_addr': Use inet_pton() or InetPton() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings
1>          C:\Program Files (x86)\Windows Kits\8.1\Include\um\winsock2.h(1850) : see declaration of 'inet_addr'
1>socketft.cpp(136): warning C4996: 'inet_addr': Use inet_pton() or InetPton() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings
1>          C:\Program Files (x86)\Windows Kits\8.1\Include\um\winsock2.h(1850) : see declaration of 'inet_addr'
1>socketft.cpp(140): warning C4996: 'gethostbyname': Use getaddrinfo() or GetAddrInfoW() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings
1>          C:\Program Files (x86)\Windows Kits\8.1\Include\um\winsock2.h(2238) : see declaration of 'gethostbyname'
1>  sosemanuk.cpp
1>  square.cpp
1>  Generating Code...
1>  Compiling...
1>  squaretb.cpp
1>  strciphr.cpp
1>  tea.cpp
1>  tftables.cpp
1>  tiger.cpp
1>  tigertab.cpp
1>  trdlocal.cpp
1>  ttmac.cpp
1>  twofish.cpp
1>  vmac.cpp
1>  wait.cpp
1>  wake.cpp
1>  whrlpool.cpp
1>  winpipes.cpp
1>  xtr.cpp
1>  xtrcrypt.cpp
1>  zdeflate.cpp
1>  zinflate.cpp
1>  zlib.cpp
1>  Generating Code...
1>  dll.cpp
1>  iterhash.cpp
1>  Generating Code...
1>eccrypto.obj : warning LNK4221: This object file does not define any previously undefined public symbols, so it will not be used by any link operation that consumes this library
1>  cryptlib.vcxproj -> C:\aMule\cryptopp\.\Debug\cryptlib.lib
2>------ Build started: Project: buildlibext, Configuration: Debug30 Win32 ------
2>  Microsoft (R) Library Manager Version 12.00.30723.0
2>  Copyright (C) Microsoft Corporation.  All rights reserved.
2> 
2>LINK : fatal error LNK1181: cannot open input file '..\..\..\..\..\..\cryptopp\win32\output\debug\cryptlib.lib'
2>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(132,5): error MSB3073: The command "if not exist ..\..\Debug30 mkdir ..\..\Debug30
2>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(132,5): error MSB3073: lib /LTCG /out:..\..\Debug30\libext.lib "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxjpegd.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxzlibd.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxbase30ud.lib" "..\..\..\..\..\..\cryptopp\win32\output\debug\cryptlib.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxtiffd.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxbase30ud_net.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxmsw30ud_core.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxpngd.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxmsw30ud_adv.lib" "..\..\..\..\..\..\wxWidgets30\lib\vc_lib\wxregexud.lib"
2>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(132,5): error MSB3073:
2>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(132,5): error MSB3073: :VCEnd" exited with code 1181.
========== Build: 1 succeeded, 1 failed, 10 up-to-date, 0 skipped ==========
« Last Edit: October 19, 2014, 10:39:13 PM by iZeus83 »
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: Problem when compiling in windows...
« Reply #3 on: October 20, 2014, 07:24:27 PM »

For me it's
Code: [Select]
1>  Generating Code...
1>  cryptlib.vcxproj -> E:\amule\dev\SVN\cryptopp\Win32\Output\Debug\cryptlib.lib
Did you mess with the paths?
What is your exact folder setup?
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

iZeus83

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 9
Re: Problem when compiling in windows...
« Reply #4 on: October 21, 2014, 09:48:48 AM »

Hi.

I only have two folders inside cryptopp, (TestData, TestVectors), you have this when you unzip cryptopp562.zip. Maybe I need to prebuild this and then win32 folder it will generate?

thank you...
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: Problem when compiling in windows...
« Reply #5 on: October 21, 2014, 10:33:07 PM »

Ok, could reproduce it.
- open cryptopp/cryptlib.vcproj in visual studio
- convert projects as prompted
- close studio without building anything
- open aMule-MSVC12E-ExtLibs30.sln, possibly reload cryptlib if it is greyed out
- for debug build change cryptlib code generation to "Multi-threaded Debug DLL (/MDd)" (as described in the wiki)
- build the sucker  8)
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

iZeus83

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 9
Re: Problem when compiling in windows...
« Reply #6 on: October 22, 2014, 09:35:30 AM »

Well, thank you for reply.

It seems you need to do something with the output paths for cryplib because I copied the "Release" folder into (/win32/output/) inside of cryptopp folder and then you can build "aMule-MSVC12E-ExtLibs30.sln"without any errors.

So if you run "aMule-MSVC12E" you need to change to "Release30" and then press F7. But I get this errors:

Code: [Select]
14>..\..\..\..\src\ExternalConnector.cpp(211): error C2614: 'CaMuleExternalConnector' : illegal member initialization: 'm_InputLine' is not a base or member for aMuleCMD and aMuleWeb.

The others are built successfull.
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: Problem when compiling in windows...
« Reply #7 on: October 22, 2014, 08:48:27 PM »

Hmm, output paths work out of the box for me. Maybe I'll have to try building from an all clear working copy.

But I get this errors:

Code: [Select]
14>..\..\..\..\src\ExternalConnector.cpp(211): error C2614: 'CaMuleExternalConnector' : illegal member initialization: 'm_InputLine' is not a base or member for aMuleCMD and aMuleWeb.
Well, things like that can happen if you build SVN versions.  ;)
Switch your working copy back to 10853 and it will work.
Gonosztopi, I'd just revert 10854 (I'd rather have one useless member in a sparsely used structure than an ifdef just for that).
Or should I clutter the ctor with a second ifdef?
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon

iZeus83

  • Approved Newbie
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 9
Re: Problem when compiling in windows...
« Reply #8 on: October 23, 2014, 09:07:44 AM »

Hi.

Finally this stupid problem of compilation was successfull, version 10853  ;D 

So take a look when you have a little time to see the output files from cryplib in a clean environment, you will see the output folder that is created.

Thanks for all Stu.
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: Problem when compiling in windows...
« Reply #9 on: October 23, 2014, 11:05:33 PM »

Gonosztopi, I'd just revert 10854 (I'd rather have one useless member in a sparsely used structure than an ifdef just for that).
Reverted. You're right, it doesn't worth the effort.
Logged
concordia cum veritate