1

Now I can compile successfully by using make file provided, now I want to compile the project to dll file, how should I modify the make file?

The make file is:

default: all

# -------------------------------------------------------------------
# Change the path to Z3 4.1.1 accordingly
# The directory indicated by this path should contain "lib" and "bin"
# e.g. "/home/z3_src_4.1.1"
#      "/home/work/tool/z3/z3_src_4.1.1"
# -------------------------------------------------------------------
Z3_path = ../z3

JUNK = S3
SOURCE = strTheory.cpp testMain.cpp
INCLUDE = $(Z3_path)/lib
LIB = $(Z3_path)/bin/external

all: $(SOURCE)
    g++ -std=c++14 -O3 -fopenmp -static -I$(INCLUDE) -L$(LIB) $(SOURCE) -lz3 -lrt -o S3 -Wall
    @echo ""

clean:
    rm -f $(JUNK)

1 Answers1

1

From your comment I assume you are asking about

  • Cross-Compilation for Windows

This is an entirely different subject. It requires more than just changing your makefile. However, this question has been asked before:

If your project is in C or C++ you can use MinGW tools and the same sort of linux based compile tools that use gcc/g++. You can install MinGW like this:

sudo apt-get install gcc-mingw32

I suggest that you study this guide for qt/win32 cross compiling using MinGW tools.

If your project is mainly for C#, you might be better off with MonoDevelop. From their website:

MonoDevelop enables developers to quickly write desktop and web applications on Linux, Windows and Mac OS X. It also makes it easy for developers to port .NET applications created with Visual Studio to Linux and Mac OS X maintaining a single code base for all platforms.

user23573
  • 515
  • 1
  • 5
  • 19