a45f694d3850fd39f3b1c4356100087b7f96b104
[profile/ivi/qtbase.git] / tests / auto / corelib / plugin / qlibrary / lib2 / lib2.pro
1 TEMPLATE = lib
2 CONFIG += dll
3 CONFIG -= staticlib
4 SOURCES         = mylib.c
5 TARGET = mylib
6 DESTDIR = ../
7 VERSION = 2
8 QT = core
9
10 wince*: DEFINES += WIN32_MSVC
11 win32-msvc: DEFINES += WIN32_MSVC
12 win32-borland: DEFINES += WIN32_BORLAND
13
14 # Force a copy of the library to have an extension that is non-standard.
15 # We want to test if we can load a shared library with *any* filename...
16
17 win32 {
18     CONFIG(debug, debug|release) {
19         BUILD_FOLDER = debug
20     } else {
21         BUILD_FOLDER = release
22     }
23     DESTDIR = ../$$BUILD_FOLDER/
24
25     # vcproj and Makefile generators refer to target differently
26     contains(TEMPLATE,vc.*) {
27         src = $(TargetPath)
28     } else {
29         src = $(DESTDIR_TARGET)
30     }
31     files = $$BUILD_FOLDER$${QMAKE_DIR_SEP}mylib.dl2 $$BUILD_FOLDER$${QMAKE_DIR_SEP}system.qt.test.mylib.dll
32 } else {
33     src = $(DESTDIR)$(TARGET)
34     files = libmylib.so2 system.qt.test.mylib.so
35 }
36
37 # This project is testdata for tst_qlibrary
38 target.path = $$[QT_INSTALL_TESTS]$${QMAKE_DIR_SEP}tst_qlibrary
39 renamed_target.path = $$target.path
40
41 for(file, files) {
42     QMAKE_POST_LINK += $$QMAKE_COPY $$src ..$$QMAKE_DIR_SEP$$file &&
43     renamed_target.extra += $$QMAKE_COPY $$src $(INSTALL_ROOT)$${target.path}$$QMAKE_DIR_SEP$$file &&
44     CLEAN_FILES += ..$$QMAKE_DIR_SEP$$file
45 }
46 renamed_target.extra = $$member(renamed_target.extra, 0, -2)
47 QMAKE_POST_LINK = $$member(QMAKE_POST_LINK, 0, -2)
48
49 INSTALLS += target renamed_target
50 DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0