From 45c8557dc67b7e8af8cef1aeb8b662dc9a6a4286 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Fri, 1 Jul 2016 14:43:51 +0530 Subject: Fix tests for the new library/executable naming scheme Also add new tests for the platform-specific and compiler-specific versioning scheme. A rough summary is: 1. A bug in how run_tests.py:validate_install checked for files has been fixed. Earlier it wasn't checking the install directory properly. 2. Shared libraries are no longer installed in common tests, and the library name/path testing is now done in platform-specific tests. 3. Executables are now always called something?exe in the installed_files.txt file, and the suffix automatically corrected depending on the platform. 4. If a test installs a file called 'no-installed-files', the installed files for that test are not validated. This is required to implement compiler-specific tests for library names/paths such as MSVC vs MinGW 5. The platform-specific file renaming in run_tests.py has been mostly removed since it is broken for shared libraries and isn't needed for static libraries. 6. run_tests.py now reports all missing and extra files. The logic for finding these has been reworked. --- run_tests.py | 66 ++++++++++++---------- .../common/27 library versions/installed_files.txt | 4 +- test cases/common/27 library versions/meson.build | 9 +-- .../common/46 library chain/installed_files.txt | 5 +- .../common/46 library chain/subdir/meson.build | 2 +- .../46 library chain/subdir/subdir2/meson.build | 2 +- .../46 library chain/subdir/subdir3/meson.build | 2 +- .../common/49 subproject/installed_files.txt | 3 +- .../49 subproject/subprojects/sublib/meson.build | 2 +- .../common/51 pkgconfig-gen/installed_files.txt | 1 - test cases/common/51 pkgconfig-gen/meson.build | 2 +- .../52 custom install dirs/installed_files.txt | 2 +- test cases/common/6 linkshared/installed_files.txt | 3 +- test cases/common/6 linkshared/meson.build | 2 +- .../common/60 install script/installed_files.txt | 2 +- test cases/common/60 install script/meson.build | 2 +- test cases/common/60 install script/myinstall.bat | 3 - test cases/common/60 install script/myinstall.sh | 4 +- .../common/60 install script/no-installed-files | 0 test cases/common/67 foreach/installed_files.txt | 6 +- test cases/common/8 install/installed_files.txt | 3 +- test cases/common/8 install/meson.build | 1 - test cases/common/8 install/shar.c | 1 - test cases/csharp/2 library/installed_files.txt | 2 +- .../7 library versions/installed_files.txt | 9 +++ test cases/linuxlike/7 library versions/lib.c | 3 + .../linuxlike/7 library versions/meson.build | 18 ++++++ .../osx/2 library versions/installed_files.txt | 4 ++ test cases/osx/2 library versions/lib.c | 3 + test cases/osx/2 library versions/meson.build | 18 ++++++ test cases/rust/1 basic/installed_files.txt | 2 +- test cases/rust/2 sharedlib/installed_files.txt | 2 +- test cases/rust/3 staticlib/installed_files.txt | 2 +- .../7 mingw dll versioning/installed_files.txt | 4 ++ test cases/windows/7 mingw dll versioning/lib.c | 6 ++ .../windows/7 mingw dll versioning/meson.build | 17 ++++++ .../7 mingw dll versioning/no-installed-files | 0 .../8 msvc dll versioning/installed_files.txt | 4 ++ test cases/windows/8 msvc dll versioning/lib.c | 6 ++ .../windows/8 msvc dll versioning/meson.build | 16 ++++++ .../8 msvc dll versioning/no-installed-files | 0 41 files changed, 171 insertions(+), 72 deletions(-) delete mode 100644 test cases/common/60 install script/myinstall.bat create mode 100644 test cases/common/60 install script/no-installed-files delete mode 100644 test cases/common/8 install/shar.c create mode 100644 test cases/linuxlike/7 library versions/installed_files.txt create mode 100644 test cases/linuxlike/7 library versions/lib.c create mode 100644 test cases/linuxlike/7 library versions/meson.build create mode 100644 test cases/osx/2 library versions/installed_files.txt create mode 100644 test cases/osx/2 library versions/lib.c create mode 100644 test cases/osx/2 library versions/meson.build create mode 100644 test cases/windows/7 mingw dll versioning/installed_files.txt create mode 100644 test cases/windows/7 mingw dll versioning/lib.c create mode 100644 test cases/windows/7 mingw dll versioning/meson.build create mode 100644 test cases/windows/7 mingw dll versioning/no-installed-files create mode 100644 test cases/windows/8 msvc dll versioning/installed_files.txt create mode 100644 test cases/windows/8 msvc dll versioning/lib.c create mode 100644 test cases/windows/8 msvc dll versioning/meson.build create mode 100644 test cases/windows/8 msvc dll versioning/no-installed-files diff --git a/run_tests.py b/run_tests.py index 6f51a19..1130bad 100755 --- a/run_tests.py +++ b/run_tests.py @@ -124,44 +124,50 @@ def setup_commands(backend): test_commands = [ninja_command, 'test', 'benchmark'] install_commands = [ninja_command, 'install'] -def platform_fix_filename(fname): - if mesonlib.is_osx(): - if fname.endswith('.so'): - return fname[:-2] + 'dylib' - return fname.replace('.so.', '.dylib.') - elif mesonlib.is_windows(): - if fname.endswith('.so'): - (p, f) = os.path.split(fname) - f = f[3:-2] + 'dll' - return os.path.join(p, f) - if fname.endswith('.a'): - return fname[:-1] + 'lib' +def get_relative_files_list_from_dir(fromdir): + paths = [] + for (root, _, files) in os.walk(fromdir): + reldir = os.path.relpath(root, start=fromdir) + for f in files: + path = os.path.join(reldir, f).replace('\\', '/') + if path.startswith('./'): + path = path[2:] + paths.append(path) + return paths + +def platform_fix_exe_name(fname): + if not fname.endswith('?exe'): + return fname + fname = fname[:-4] + if mesonlib.is_windows(): + return fname + '.exe' return fname def validate_install(srcdir, installdir): - if mesonlib.is_windows(): - # Don't really know how Windows installs should work - # so skip. - return '' info_file = os.path.join(srcdir, 'installed_files.txt') expected = {} found = {} + ret_msg = '' + # Test expects to not install any files + if os.path.exists(os.path.join(installdir, 'usr', 'no-installed-files')): + return '' + # Generate list of expected files if os.path.exists(info_file): for line in open(info_file): - expected[platform_fix_filename(line.strip())] = True - for root, _, files in os.walk(installdir): - for fname in files: - found_name = os.path.join(root, fname)[len(installdir)+1:] - found[found_name] = True - expected = set(expected) - found = set(found) - missing = expected - found - for fname in missing: - return 'Expected file %s missing.' % fname - extra = found - expected - for fname in extra: - return 'Found extra file %s.' % fname - return '' + expected[platform_fix_exe_name(line.strip())] = False + # Check if expected files were found + for fname in expected: + if os.path.exists(os.path.join(installdir, fname)): + expected[fname] = True + for (fname, found) in expected.items(): + if not found: + ret_msg += 'Expected file {0} missing.\n'.format(fname) + # Check if there are any unexpected files + found = get_relative_files_list_from_dir(installdir) + for fname in found: + if fname not in expected: + ret_msg += 'Extra file {0} found.\n'.format(fname) + return ret_msg def log_text_file(logfile, testdir, stdo, stde): global stop, executor, futures diff --git a/test cases/common/27 library versions/installed_files.txt b/test cases/common/27 library versions/installed_files.txt index a218d29..e10d1dd 100644 --- a/test cases/common/27 library versions/installed_files.txt +++ b/test cases/common/27 library versions/installed_files.txt @@ -1,3 +1 @@ -usr/lib/libsomelib.so -usr/lib/libsomelib.so.0 -usr/lib/libsomelib.so.1.2.3 +usr/lib/prefixsomelib.suffix diff --git a/test cases/common/27 library versions/meson.build b/test cases/common/27 library versions/meson.build index cebcd64..3b2c6e9 100644 --- a/test cases/common/27 library versions/meson.build +++ b/test cases/common/27 library versions/meson.build @@ -1,6 +1,7 @@ project('library versions', 'c') -lib = shared_library('somelib', 'lib.c', \ -version : '1.2.3', \ -soversion : '0', \ -install : true) +shared_library('somelib', 'lib.c', + name_prefix : 'prefix', + name_suffix : 'suffix', + install_dir : 'lib', + install : true) diff --git a/test cases/common/46 library chain/installed_files.txt b/test cases/common/46 library chain/installed_files.txt index 8d38fd9..c7dab9f 100644 --- a/test cases/common/46 library chain/installed_files.txt +++ b/test cases/common/46 library chain/installed_files.txt @@ -1,4 +1 @@ -usr/bin/prog -usr/lib/liblib1.so -usr/lib/liblib2.so -usr/lib/liblib3.so +usr/bin/prog?exe diff --git a/test cases/common/46 library chain/subdir/meson.build b/test cases/common/46 library chain/subdir/meson.build index c165abe..ab71bda 100644 --- a/test cases/common/46 library chain/subdir/meson.build +++ b/test cases/common/46 library chain/subdir/meson.build @@ -1,4 +1,4 @@ subdir('subdir2') subdir('subdir3') -lib1 = shared_library('lib1', 'lib1.c', install : true, link_with : [lib2, lib3]) +lib1 = shared_library('lib1', 'lib1.c', install : false, link_with : [lib2, lib3]) diff --git a/test cases/common/46 library chain/subdir/subdir2/meson.build b/test cases/common/46 library chain/subdir/subdir2/meson.build index 2281e4b..befd94d 100644 --- a/test cases/common/46 library chain/subdir/subdir2/meson.build +++ b/test cases/common/46 library chain/subdir/subdir2/meson.build @@ -1 +1 @@ -lib2 = shared_library('lib2', 'lib2.c', install : true) +lib2 = shared_library('lib2', 'lib2.c', install : false) diff --git a/test cases/common/46 library chain/subdir/subdir3/meson.build b/test cases/common/46 library chain/subdir/subdir3/meson.build index f049c79..7bd249a 100644 --- a/test cases/common/46 library chain/subdir/subdir3/meson.build +++ b/test cases/common/46 library chain/subdir/subdir3/meson.build @@ -1 +1 @@ -lib3 = shared_library('lib3', 'lib3.c', install : true) +lib3 = shared_library('lib3', 'lib3.c', install : false) diff --git a/test cases/common/49 subproject/installed_files.txt b/test cases/common/49 subproject/installed_files.txt index f2e1e27..dc09fb7 100644 --- a/test cases/common/49 subproject/installed_files.txt +++ b/test cases/common/49 subproject/installed_files.txt @@ -1,3 +1,2 @@ -usr/bin/user -usr/lib/libsublib.so +usr/bin/user?exe usr/share/sublib/sublib.depmf diff --git a/test cases/common/49 subproject/subprojects/sublib/meson.build b/test cases/common/49 subproject/subprojects/sublib/meson.build index 269f815..acaf1bf 100644 --- a/test cases/common/49 subproject/subprojects/sublib/meson.build +++ b/test cases/common/49 subproject/subprojects/sublib/meson.build @@ -13,7 +13,7 @@ if meson.project_version() != '1.0.0' endif i = include_directories('include') -l = shared_library('sublib', 'sublib.c', include_directories : i, install : true, +l = shared_library('sublib', 'sublib.c', include_directories : i, install : false, c_args : '-DBUILDING_SUB=2') t = executable('simpletest', 'simpletest.c', include_directories : i, link_with : l) test('plain', t) diff --git a/test cases/common/51 pkgconfig-gen/installed_files.txt b/test cases/common/51 pkgconfig-gen/installed_files.txt index cc5d34b..d6a23d7 100644 --- a/test cases/common/51 pkgconfig-gen/installed_files.txt +++ b/test cases/common/51 pkgconfig-gen/installed_files.txt @@ -1,3 +1,2 @@ usr/include/simple.h -usr/lib/libsimple.so usr/lib/pkgconfig/simple.pc diff --git a/test cases/common/51 pkgconfig-gen/meson.build b/test cases/common/51 pkgconfig-gen/meson.build index 4044b3d..b5f6921 100644 --- a/test cases/common/51 pkgconfig-gen/meson.build +++ b/test cases/common/51 pkgconfig-gen/meson.build @@ -2,7 +2,7 @@ project('pkgconfig-gen', 'c') pkgg = import('pkgconfig') -lib = shared_library('simple', 'simple.c', install : true) +lib = shared_library('simple', 'simple.c') libver = '1.0' h = install_headers('simple.h') diff --git a/test cases/common/52 custom install dirs/installed_files.txt b/test cases/common/52 custom install dirs/installed_files.txt index dc495e2..1b8b561 100644 --- a/test cases/common/52 custom install dirs/installed_files.txt +++ b/test cases/common/52 custom install dirs/installed_files.txt @@ -1,4 +1,4 @@ -usr/dib/dab/dub/prog +usr/dib/dab/dub/prog?exe usr/some/dir/sample.h usr/woman/prog.1.gz usr/meow/datafile.cat diff --git a/test cases/common/6 linkshared/installed_files.txt b/test cases/common/6 linkshared/installed_files.txt index 2a4c330..c7dab9f 100644 --- a/test cases/common/6 linkshared/installed_files.txt +++ b/test cases/common/6 linkshared/installed_files.txt @@ -1,2 +1 @@ -usr/bin/prog -usr/lib/libmylib.so +usr/bin/prog?exe diff --git a/test cases/common/6 linkshared/meson.build b/test cases/common/6 linkshared/meson.build index 1ecb052..846b4a0 100644 --- a/test cases/common/6 linkshared/meson.build +++ b/test cases/common/6 linkshared/meson.build @@ -2,7 +2,7 @@ project('shared library linking test', 'c', 'cpp') lib = shared_library('mylib', 'libfile.c' # Split to different lines before and after the comma to test parser. - , install : true) + , install : false) # Don't install libraries in common tests; the path is platform-specific exe = executable('prog', 'main.c', link_with : lib, install : true) test('runtest', exe) diff --git a/test cases/common/60 install script/installed_files.txt b/test cases/common/60 install script/installed_files.txt index 58315f9..94e3164 100644 --- a/test cases/common/60 install script/installed_files.txt +++ b/test cases/common/60 install script/installed_files.txt @@ -1,2 +1,2 @@ -usr/bin/prog +usr/bin/prog?exe usr/diiba/daaba/file.dat diff --git a/test cases/common/60 install script/meson.build b/test cases/common/60 install script/meson.build index 66db0a7..cb87e45 100644 --- a/test cases/common/60 install script/meson.build +++ b/test cases/common/60 install script/meson.build @@ -1,7 +1,7 @@ project('custom install script', 'c') if meson.get_compiler('c').get_id() == 'msvc' - meson.add_install_script('myinstall.bat') + install_data('no-installed-files', install_dir : '') else meson.add_install_script('myinstall.sh') endif diff --git a/test cases/common/60 install script/myinstall.bat b/test cases/common/60 install script/myinstall.bat deleted file mode 100644 index 7036077..0000000 --- a/test cases/common/60 install script/myinstall.bat +++ /dev/null @@ -1,3 +0,0 @@ -@ECHO OFF - -echo At this point we could do something. diff --git a/test cases/common/60 install script/myinstall.sh b/test cases/common/60 install script/myinstall.sh index 42a415e..79512c9 100755 --- a/test cases/common/60 install script/myinstall.sh +++ b/test cases/common/60 install script/myinstall.sh @@ -4,9 +4,7 @@ set -eu echo Starting custom installation step -# These commands fail on Windows, but we don't really care. - mkdir -p "${DESTDIR}${MESON_INSTALL_PREFIX}/diiba/daaba" touch "${DESTDIR}${MESON_INSTALL_PREFIX}/diiba/daaba/file.dat" -echo Finishing custom install step +echo Finished custom install step diff --git a/test cases/common/60 install script/no-installed-files b/test cases/common/60 install script/no-installed-files new file mode 100644 index 0000000..e69de29 diff --git a/test cases/common/67 foreach/installed_files.txt b/test cases/common/67 foreach/installed_files.txt index 36c6386..2930ff0 100644 --- a/test cases/common/67 foreach/installed_files.txt +++ b/test cases/common/67 foreach/installed_files.txt @@ -1,3 +1,3 @@ -usr/bin/prog1 -usr/bin/prog2 -usr/bin/prog3 +usr/bin/prog1?exe +usr/bin/prog2?exe +usr/bin/prog3?exe diff --git a/test cases/common/8 install/installed_files.txt b/test cases/common/8 install/installed_files.txt index 1e9166b..3bc66ab 100644 --- a/test cases/common/8 install/installed_files.txt +++ b/test cases/common/8 install/installed_files.txt @@ -1,3 +1,2 @@ -usr/bin/prog -usr/lib/libshar.so +usr/bin/prog?exe usr/lib/libstat.a diff --git a/test cases/common/8 install/meson.build b/test cases/common/8 install/meson.build index 677a2ee..92ff3a0 100644 --- a/test cases/common/8 install/meson.build +++ b/test cases/common/8 install/meson.build @@ -1,5 +1,4 @@ project('install test', 'c') stlib = static_library('stat', 'stat.c', install : true) -shlib = shared_library('shar', 'shar.c', install : true) exe = executable('prog', 'prog.c', install : true) diff --git a/test cases/common/8 install/shar.c b/test cases/common/8 install/shar.c deleted file mode 100644 index 9c816a6..0000000 --- a/test cases/common/8 install/shar.c +++ /dev/null @@ -1 +0,0 @@ -int func() { return 15; } diff --git a/test cases/csharp/2 library/installed_files.txt b/test cases/csharp/2 library/installed_files.txt index b830634..4ebea55 100644 --- a/test cases/csharp/2 library/installed_files.txt +++ b/test cases/csharp/2 library/installed_files.txt @@ -1,2 +1,2 @@ usr/bin/prog.exe -usr/lib/libhelper.dll +usr/lib/helper.dll diff --git a/test cases/linuxlike/7 library versions/installed_files.txt b/test cases/linuxlike/7 library versions/installed_files.txt new file mode 100644 index 0000000..b997e53 --- /dev/null +++ b/test cases/linuxlike/7 library versions/installed_files.txt @@ -0,0 +1,9 @@ +usr/lib/libsome.so +usr/lib/libsome.so.0 +usr/lib/libsome.so.1.2.3 +usr/lib/libnoversion.so +usr/lib/libonlyversion.so +usr/lib/libonlyversion.so.1 +usr/lib/libonlyversion.so.1.4.5 +usr/lib/libonlysoversion.so +usr/lib/libonlysoversion.so.5 diff --git a/test cases/linuxlike/7 library versions/lib.c b/test cases/linuxlike/7 library versions/lib.c new file mode 100644 index 0000000..67b6f4d --- /dev/null +++ b/test cases/linuxlike/7 library versions/lib.c @@ -0,0 +1,3 @@ +int myFunc() { + return 55; +} diff --git a/test cases/linuxlike/7 library versions/meson.build b/test cases/linuxlike/7 library versions/meson.build new file mode 100644 index 0000000..504aa4e --- /dev/null +++ b/test cases/linuxlike/7 library versions/meson.build @@ -0,0 +1,18 @@ +project('library versions', 'c') + +shared_library('some', 'lib.c', + version : '1.2.3', + soversion : '0', + install : true) + +shared_library('noversion', 'lib.c', + install : true) + +shared_library('onlyversion', 'lib.c', + version : '1.4.5', + install : true) + +shared_library('onlysoversion', 'lib.c', + # Also test that int soversion is acceptable + soversion : 5, + install : true) diff --git a/test cases/osx/2 library versions/installed_files.txt b/test cases/osx/2 library versions/installed_files.txt new file mode 100644 index 0000000..66470ab --- /dev/null +++ b/test cases/osx/2 library versions/installed_files.txt @@ -0,0 +1,4 @@ +usr/lib/libsome.0.dylib +usr/lib/libnoversion.dylib +usr/lib/libonlyversion.1.dylib +usr/lib/libonlysoversion.5.dylib diff --git a/test cases/osx/2 library versions/lib.c b/test cases/osx/2 library versions/lib.c new file mode 100644 index 0000000..67b6f4d --- /dev/null +++ b/test cases/osx/2 library versions/lib.c @@ -0,0 +1,3 @@ +int myFunc() { + return 55; +} diff --git a/test cases/osx/2 library versions/meson.build b/test cases/osx/2 library versions/meson.build new file mode 100644 index 0000000..504aa4e --- /dev/null +++ b/test cases/osx/2 library versions/meson.build @@ -0,0 +1,18 @@ +project('library versions', 'c') + +shared_library('some', 'lib.c', + version : '1.2.3', + soversion : '0', + install : true) + +shared_library('noversion', 'lib.c', + install : true) + +shared_library('onlyversion', 'lib.c', + version : '1.4.5', + install : true) + +shared_library('onlysoversion', 'lib.c', + # Also test that int soversion is acceptable + soversion : 5, + install : true) diff --git a/test cases/rust/1 basic/installed_files.txt b/test cases/rust/1 basic/installed_files.txt index 61eda27..c7dab9f 100644 --- a/test cases/rust/1 basic/installed_files.txt +++ b/test cases/rust/1 basic/installed_files.txt @@ -1 +1 @@ -usr/bin/prog +usr/bin/prog?exe diff --git a/test cases/rust/2 sharedlib/installed_files.txt b/test cases/rust/2 sharedlib/installed_files.txt index 5a7c7d6..85acff2 100644 --- a/test cases/rust/2 sharedlib/installed_files.txt +++ b/test cases/rust/2 sharedlib/installed_files.txt @@ -1,2 +1,2 @@ -usr/bin/prog +usr/bin/prog?exe usr/lib/libstuff.rlib diff --git a/test cases/rust/3 staticlib/installed_files.txt b/test cases/rust/3 staticlib/installed_files.txt index 5a7c7d6..85acff2 100644 --- a/test cases/rust/3 staticlib/installed_files.txt +++ b/test cases/rust/3 staticlib/installed_files.txt @@ -1,2 +1,2 @@ -usr/bin/prog +usr/bin/prog?exe usr/lib/libstuff.rlib diff --git a/test cases/windows/7 mingw dll versioning/installed_files.txt b/test cases/windows/7 mingw dll versioning/installed_files.txt new file mode 100644 index 0000000..8c2a8f2 --- /dev/null +++ b/test cases/windows/7 mingw dll versioning/installed_files.txt @@ -0,0 +1,4 @@ +usr/bin/libsome-0.dll +usr/lib/libsome.dll.a +usr/bin/libnoversion.dll +usr/lib/libnoversion.dll.a diff --git a/test cases/windows/7 mingw dll versioning/lib.c b/test cases/windows/7 mingw dll versioning/lib.c new file mode 100644 index 0000000..cf7dfdd --- /dev/null +++ b/test cases/windows/7 mingw dll versioning/lib.c @@ -0,0 +1,6 @@ +#ifdef _WIN32 +__declspec(dllexport) +#endif +int myFunc() { + return 55; +} diff --git a/test cases/windows/7 mingw dll versioning/meson.build b/test cases/windows/7 mingw dll versioning/meson.build new file mode 100644 index 0000000..23a3343 --- /dev/null +++ b/test cases/windows/7 mingw dll versioning/meson.build @@ -0,0 +1,17 @@ +project('mingw dll versioning', 'c') + +cc = meson.get_compiler('c') + +# Test that MinGW/GCC creates correctly-named dll files and dll.a files, +# and also installs them in the right place +if cc.get_id() != 'msvc' + shared_library('some', 'lib.c', + version : '1.2.3', + soversion : '0', + install : true) + + shared_library('noversion', 'lib.c', + install : true) +else + install_data('no-installed-files', install_dir : '') +endif diff --git a/test cases/windows/7 mingw dll versioning/no-installed-files b/test cases/windows/7 mingw dll versioning/no-installed-files new file mode 100644 index 0000000..e69de29 diff --git a/test cases/windows/8 msvc dll versioning/installed_files.txt b/test cases/windows/8 msvc dll versioning/installed_files.txt new file mode 100644 index 0000000..5f6e26a --- /dev/null +++ b/test cases/windows/8 msvc dll versioning/installed_files.txt @@ -0,0 +1,4 @@ +usr/bin/some-0.dll +usr/lib/some.lib +usr/bin/noversion.dll +usr/lib/noversion.lib diff --git a/test cases/windows/8 msvc dll versioning/lib.c b/test cases/windows/8 msvc dll versioning/lib.c new file mode 100644 index 0000000..cf7dfdd --- /dev/null +++ b/test cases/windows/8 msvc dll versioning/lib.c @@ -0,0 +1,6 @@ +#ifdef _WIN32 +__declspec(dllexport) +#endif +int myFunc() { + return 55; +} diff --git a/test cases/windows/8 msvc dll versioning/meson.build b/test cases/windows/8 msvc dll versioning/meson.build new file mode 100644 index 0000000..0c36173 --- /dev/null +++ b/test cases/windows/8 msvc dll versioning/meson.build @@ -0,0 +1,16 @@ +project('msvc dll versioning', 'c') + +cc = meson.get_compiler('c') + +# Test that MSVC creates foo-0.dll and bar.dll +if cc.get_id() == 'msvc' + shared_library('some', 'lib.c', + version : '1.2.3', + soversion : '0', + install : true) + + shared_library('noversion', 'lib.c', + install : true) +else + install_data('no-installed-files', install_dir : '') +endif diff --git a/test cases/windows/8 msvc dll versioning/no-installed-files b/test cases/windows/8 msvc dll versioning/no-installed-files new file mode 100644 index 0000000..e69de29 -- cgit v1.1