Quantcast
Channel: Active questions tagged header - Stack Overflow
Viewing all articles
Browse latest Browse all 707

How to use CMake to get command line output as an argument?

$
0
0

I'm using CMake to build linux module mode, so I'm retrieving header files on ubuntu, currently I'm running ubuntu in docker and it has:

/lib/modules/4.15.0-76-generic

Well, several days later if I build a new image, it will become updated value:

/lib/modules/4.15.0-78-generic

So this number is changing, but there's only one directory under /lib/module, and it's not 'uname -a' output.

Linux 0a08e87c0a18 4.15.0-50-generic

So I wish to know if there's a convenient way in CMake just like shell ls /lib/module, and then I can use command line output as a parameter for header/library root directory?

Thanks a lot.


Viewing all articles
Browse latest Browse all 707

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>