linker

Why is msbuild and link.exe “hanging” during a build?

人盡茶涼 提交于 2019-12-21 04:37:13
问题 We have a few C++ solutions and we run some build scripts using batch files that call msbuild.exe for each of the configurations in the solutions. This had been working fine on 3 developer machines and one build machine, but then one of the projects started to hang when linking. This only happens on the newest machine which is a quad core, 2.8ghz I think. It runs on Windows Server 2003 and the others are on XP or Vista. This happens consistently even if I change the order of builds in the bat

Using Go 1.5 buildmode=c-archive with net/http.Server linked from C

吃可爱长大的小学妹 提交于 2019-12-21 04:37:13
问题 The upcoming release of Go 1.5 comes with new buildmodes which allow for exporting Go symbols to be linked and called from C code. I've been playing around with it and got basic "Hello world" examples working, but now I'm trying to link a Go library which starts a net/http.Server and it's failing. The code looks like this (it's also available here): gohttplib.go: package main import "C" import "net/http" //export ListenAndServe func ListenAndServe(caddr *C.char) { addr := C.GoString(caddr)

C++ keep getting error LNK2019: unresolved external symbol [duplicate]

て烟熏妆下的殇ゞ 提交于 2019-12-21 04:29:27
问题 This question already has answers here : Why can templates only be implemented in the header file? (16 answers) Closed 5 years ago . I tried to google this but always come back with different issues. I am getting 3 unresolved externals when I try to compile this program: 1>main.obj : error LNK2019: unresolved external symbol "public: __thiscall DynIntStack<char>::~DynIntStack<char>(void)" (??1?$DynIntStack@D@@QAE@XZ) referenced in function _main 1>main.obj : error LNK2019: unresolved external

Is it possible to replace the global “operator new()” everywhere?

亡梦爱人 提交于 2019-12-21 04:12:54
问题 I would like to replace the global operator new() and operator delete() (along with all of their variants) in order to do some memory management tricks. I would like all code in my application to use the custom operators (including code in my own DLLs as well as third-party DLLs). I have read things to the effect that the linker will choose the first definition it sees when linking (e.g., if the library that contains your custom operator new() is linked first, it will "beat" the link with the

Speed Up linking speed / Fast linking on linux

╄→尐↘猪︶ㄣ 提交于 2019-12-21 03:52:52
问题 I am building webkit ( 2 Million lines of code) after every ten minutes to see the output of my change in it, and linking of webkit on my Machine requires to process 600-700 MB of object files which are there on my hard-disk. That takes around 1.5 minutes. I want to speedup this linking process. Is there any chance that, I can tell os to keep all the object files in RAM only ( I have 4 GB of ram ). Is there any other way to speed up the linking? Any ideas or help is appreciated! Here is a

Cannot link Boost regex

霸气de小男生 提交于 2019-12-21 03:43:06
问题 I am currently trying to compile a Contraction Hierachies implementation by KIT which requires Boost::Regex. The supplied Makefile already makes sure (and I have also double-checked this manually) that g++ is supplied with the -lboost_regex switch. If the library is not installed, g++ will complain. So I installed the library from my package sources and tried compiling again. This time I am getting a huge load of linker errors regarding Boost::Regex. Here is a short excerpt: main.o: In

dlopen vs linking overhead

点点圈 提交于 2019-12-21 02:52:15
问题 Suppose I have a library - foo.so . When building my binary (which needs this library), I can either (1) link foo.so , or, (2) within the program source code, dlopen this library and then call functions provided by this library Is there any performance difference between (1) and (2) when I call a function from the library? Note that I am aware that there will be different initialization characteristics (like the cost of the dlopen , overhead for first usage of a symbol etc) but in the steady

Visual Studio 2010 Qt Link Problem

六月ゝ 毕业季﹏ 提交于 2019-12-21 02:30:56
问题 I spent the weekend trying to figure this out and I'm on the last step. My goal: to get visual studio 2010 and Qt 4.7.3 to work together. I installed Qt from source, specifying to build with the following configuration: configure.exe -debug-and-release -opensource -platform win32-msvc2010 -no-webkit -no-phonon -no-phonon-backend -no-script -no-scripttools -no-qt3support -no-multimedia -no-ltcg After configuration, I ran nmake, no problems. In my visual studio 2010 solution, I have two

How to find the multiple definitions of a function

拟墨画扇 提交于 2019-12-21 02:07:05
问题 I wrote a findDialog which finds the text searched. When I give make command,it returns g++ -Wl,-O1 -o findDialog FindDialog.o main.o moc_FindDialog.o -L/usr/lib -lQtGui -lQtCore -lpthread moc_FindDialog.o: In function `FindDialog::findClicked()': moc_FindDialog.cpp:(.text+0x20): multiple definition of `FindDialog::findClicked()' FindDialog.o:FindDialog.cpp:(.text+0x30): first defined here moc_FindDialog.o: In function `FindDialog::enableFindButton(QString const&)': moc_FindDialog.cpp:(.text

Can't link MacOS frameworks with CMake

安稳与你 提交于 2019-12-21 01:57:25
问题 I'm trying to build a subproject with cmake (it's not an xcode project or even an app for iphone, the result is cross-platform console executable, which #includes some inherited from C++ abstract classes, written in objective-c++) I'm using this guide to link mac os frameworks: http://www.vtk.org/Wiki/CMake:HowToUseExistingOSXFrameworks and this macro: macro(ADD_FRAMEWORK fwname appname) find_library(FRAMEWORK_${fwname} NAMES ${fwname} PATHS ${CMAKE_OSX_SYSROOT}/System/Library PATH_SUFFIXES