Linker's Error Message While Building With Conda-Win10-VSC2019

Having trouble installing or compiling FreeCAD? Get help here.
UR_
Posts: 1195
Joined: Tue Jan 03, 2017 8:42 pm

Linker's Error Message While Building With Conda-Win10-VSC2019

Postby UR_ » Fri Nov 22, 2019 9:11 am

Encouraged from looo's comment somewhere in this forum concerning conda based windows builds,
I upgraded from Visual Studio Community 2017 to 2019 yesterday.

But now, there is a linker's error message building latest 0.19
46>libboost_program_options.lib(value_semantic.obj) : error LNK2005: "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > boost::program_options::arg" (?arg@program_options@boost@@3V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@A) already defined in Application.obj
46>libboost_program_options.lib(options_description.obj) : error LNK2005: "public: static unsigned int const boost::program_options::options_description::m_default_line_length" (?m_default_line_length@options_description@program_options@boost@@2IB) already defined in Application.obj
46> Creating library C:/Users/aio/Miniconda3/envs/freecad-dev/Library/src/App/Release/FreeCADApp.lib and object C:/Users/aio/Miniconda3/envs/freecad-dev/Library/src/App/Release/FreeCADApp.exp
46>C:\Users\aio\Miniconda3\envs\freecad-dev\Library\bin\FreeCADApp.dll : fatal error LNK1169: one or more multiply defined symbols found
46>Done building project "FreeCADApp.vcxproj" -- FAILED.
...
========== Build: 98 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

Any clues what's going on? :hushed:


used conda env:

Code: Select all

(freecad-dev) C:\Users\aio\Miniconda3>conda list
# packages in environment at C:\Users\aio\Miniconda3\envs\freecad-dev:
#
# Name                    Version                   Build  Channel
boost-cpp                 1.70.0               h6a4c333_2    conda-forge
bzip2                     1.0.8                hfa6e2cd_1    conda-forge
ca-certificates           2019.9.11            hecc5488_0    conda-forge
certifi                   2019.9.11                py37_0    conda-forge
coin3d                    4.0.0             h1df4a3b_1006    conda-forge
curl                      7.65.3               h4496350_0    conda-forge
cycler                    0.10.0                     py_2    conda-forge
eigen                     3.3.7             he980bc4_1001    conda-forge
expat                     2.2.5             he025d50_1004    conda-forge
freecad                   0.19.pre        py37ha28476b_67    freecad/label/dev
freetype                  2.10.0               h563cfd7_1    conda-forge
future                    0.18.2                   py37_0    conda-forge
gitdb2                    2.0.6                      py_0    conda-forge
gitpython                 3.0.5                      py_0    conda-forge
hdf4                      4.2.13            hf8e6fe8_1003    conda-forge
hdf5                      1.10.5          nompi_ha405e13_1104    conda-forge
icu                       64.2                 he025d50_1    conda-forge
intel-openmp              2019.5                      281
jpeg                      9c                hfa6e2cd_1001    conda-forge
jsoncpp                   1.8.4             h1ad3211_1002    conda-forge
kiwisolver                1.1.0            py37he980bc4_0    conda-forge
krb5                      1.16.3            hdd46e55_1001    conda-forge
libblas                   3.8.0                     8_mkl    conda-forge
libcblas                  3.8.0                     8_mkl    conda-forge
libclang                  9.0.0           default_hf44288c_4    conda-forge
libcurl                   7.65.3               h4496350_0    conda-forge
libiconv                  1.15              hfa6e2cd_1005    conda-forge
liblapack                 3.8.0                     8_mkl    conda-forge
libnetcdf                 4.7.1           nompi_h8d74e2a_101    conda-forge
libpng                    1.6.37               h7602738_0    conda-forge
libssh2                   1.8.2                h642c060_2    conda-forge
libtiff                   4.1.0                h21b02b4_1    conda-forge
libxml2                   2.9.10               h9ce36c8_0    conda-forge
libxslt                   1.1.33               heafd4d3_0    conda-forge
lz4-c                     1.8.3             he025d50_1001    conda-forge
matplotlib-base           3.1.2            py37h2981e6d_1    conda-forge
mkl                       2019.5                      281
netgen                    6.2.1808        py37h58e452a_1006    conda-forge
numpy                     1.17.3           py37hc71023c_0    conda-forge
occt                      7.3.0             hd7db75f_1005    conda-forge
openssl                   1.1.1d               hfa6e2cd_0    conda-forge
pip                       19.3.1                   py37_0    conda-forge
pivy                      0.6.5a3          py37h5c3084f_0    conda-forge
pthreads-win32            2.9.1                hfa6e2cd_3    conda-forge
pybind11                  2.4.3            py37he980bc4_0    conda-forge
pyparsing                 2.4.5                      py_0    conda-forge
pyside2                   5.13.1           py37hfa7ce6d_6    conda-forge
python                    3.7.3                h510b542_1    conda-forge
python-dateutil           2.8.1                      py_0    conda-forge
pyyaml                    3.13            py37hfa6e2cd_1001    conda-forge
qt                        5.12.5               h7ef1ec2_0    conda-forge
setuptools                41.6.0                   py37_1    conda-forge
six                       1.13.0                   py37_0    conda-forge
smesh                     8.3.0.2              h90a28c1_6    conda-forge
smmap2                    2.0.5                      py_0    conda-forge
soqt                      1.6.0a            h5c3084f_1003    conda-forge
sqlite                    3.30.1               hfa6e2cd_0    conda-forge
swig                      4.0.1                         0    conda-forge
tbb                       2019.9               he980bc4_0    conda-forge
tbb-devel                 2019.9               he980bc4_0    conda-forge
tk                        8.6.9             hfa6e2cd_1003    conda-forge
tornado                   6.0.3            py37hfa6e2cd_0    conda-forge
vc                        14.1                 h0510ff6_4
vs2015_runtime            14.16.27012          hf0eaf9b_0
vtk                       8.2.0           py37h1bb45ea_205    conda-forge
wheel                     0.33.6                   py37_0    conda-forge
wincertstore              0.2                   py37_1003    conda-forge
xerces-c                  3.2.2             h6538335_1004    conda-forge
xz                        5.2.4             h2fa13f4_1001    conda-forge
yaml                      0.2.2                         0    conda-forge
zlib                      1.2.11            h2fa13f4_1006    conda-forge
zstd                      1.4.4                hd8a0e53_1    conda-forge
UR_
Posts: 1195
Joined: Tue Jan 03, 2017 8:42 pm

Re: Linker's Error Message While Building With Conda-Win10-VSC2019

Postby UR_ » Sat Nov 23, 2019 8:48 pm

Finally I got a build using a dirty workaround


Setting FreeCADApp project properties to: :zipper_mouth_face:

Screenshot 001.png
Screenshot 001.png (48.48 KiB) Viewed 184 times

But this is too dirty :oops:


Any ideas?