]> git.alsa-project.org Git - alsa-utils.git/commitdiff
topology: define -I option only for alsa-lib 1.2.6+
authorJaroslav Kysela <perex@perex.cz>
Wed, 8 Dec 2021 08:55:44 +0000 (09:55 +0100)
committerJaroslav Kysela <perex@perex.cz>
Wed, 8 Dec 2021 08:56:38 +0000 (09:56 +0100)
Link: https://github.com/alsa-project/alsa-utils/pull/125
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
topology/topology.c

index f8062459d7cbb9cbb2a8db5aafec2b6c20919044..962e2e870e378985faf6da5674dc0fd1c9be7bc8 100644 (file)
@@ -58,6 +58,7 @@ _("Usage: %s [OPTIONS]...\n"
 "-o, --output=FILE       set output file\n"
 #if SND_LIB_VER(1, 2, 5) < SND_LIB_VERSION
 "-D, --define=ARGS       define variables (VAR1=VAL1[,VAR2=VAL2] ...)\n"
+"-I, --inc-dir=DIR       set include path\n"
 #endif
 "-s, --sort              sort the identifiers in the normalized output\n"
 "-g, --group             save configuration by group indexes\n"
@@ -381,9 +382,9 @@ static int decode(const char *source_file, const char *output_file,
 
 int main(int argc, char *argv[])
 {
-       static const char short_options[] = "hc:d:n:u:v:o:pP:sgxzVI:"
+       static const char short_options[] = "hc:d:n:u:v:o:pP:sgxzV"
 #if SND_LIB_VER(1, 2, 5) < SND_LIB_VERSION
-               "D:"
+               "D:I:"
 #endif
                ;
        static const struct option long_options[] = {
@@ -397,6 +398,7 @@ int main(int argc, char *argv[])
                {"output", 1, NULL, 'o'},
 #if SND_LIB_VER(1, 2, 5) < SND_LIB_VERSION
                {"define", 1, NULL, 'D'},
+               {"inc-dir", 1, NULL, 'I'},
 #endif
                {"sort", 0, NULL, 's'},
                {"group", 0, NULL, 'g'},
@@ -451,9 +453,11 @@ int main(int argc, char *argv[])
                        op = 'P';
                        source_file = optarg;
                        break;
+#if SND_LIB_VER(1, 2, 5) < SND_LIB_VERSION
                case 'I':
                        inc_path = optarg;
                        break;
+#endif
                case 'p':
                        pre_process_config = true;
                        break;