[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cmake
Subject:    [CMake] globs case sensitivity depends on platform
From:       🐋_Jan_Hegewald <jan.hegewald () awi ! de>
Date:       2016-01-28 11:56:36
Message-ID: 6D90D15D-D0D5-413B-831A-D98628D1AA30 () awi ! de
[Download RAW message or body]

Hi all,
I have some trouble with file globbing using the glob command like so:
	file(GLOB all_sources ${src_home}/*.F**)
the src_home contains files with uppercase and also some with lowercase suffixes, \
e.g. .F and .f (This makes an important difference to some Fortran compilers \
regarding the C preprocessor.). Now the all_sources does not contain the same list of \
files on different platforms: On my Mac, the F* glob returns the F* and the f* files, \
whereas on linux it only returns the F* files. I tested with a case sensitive \
filesystem on the Mac too, same result: uppercase and lowercase are returned. The \
cmake on both tested systems is "cmake version 3.4.3".

My current solution is this:
	file(GLOB all_sources ${src_home}/*.F** ${src_home}/*.f**)
	list(REMOVE_DUPLICATES all_sources)

Am I missing something obvious here? Do you know a better workaround? I think this is \
an error with cmakes glob, where can I report it?

Many TIA,
Jan
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: \
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information \
on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at \
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic