]> git.pld-linux.org Git - packages/rpm-specdump.git/commitdiff
inline commonly used macros auto/th/rpm-specdump-0.6-1
authorElan Ruusamäe <glen@delfi.ee>
Mon, 24 Nov 2014 19:32:59 +0000 (21:32 +0200)
committerElan Ruusamäe <glen@delfi.ee>
Mon, 24 Nov 2014 19:32:59 +0000 (21:32 +0200)
rpm-specdump.c

index 9b473b5e22076b650a99d166899eff808ac02b77..f1a820001e8a0f74eaec529bd10315ddc10206da 100644 (file)
@@ -285,6 +285,16 @@ struct Arguments args = { 0,0,0,-1,-1, {0,0,0}, 0 };
 Spec s;
 
        addDefine(&args, "patch %{nil}");
+
+       // instead of requiring rpm-build, we include some "builtin" macros
+       addDefine(&args, "bcond_without() %{expand:%%{!?_without_%{1}:%%global with_%{1} 1}}");
+       addDefine(&args, "bcond_with() %{expand:%%{?_with_%{1}:%%global with_%{1} 1}}");
+       addDefine(&args, "with() %{expand:%%{?with_%{1}:1}%%{!?with_%{1}:0}}");
+       addDefine(&args, "without() %{expand:%%{?with_%{1}:0}%%{!?with_%{1}:1}}");
+
+       // include macros.perl, etc
+       addDefine(&args, "include() %{nil}");
+
        parseArgs(&args, argc, argv);
 
        if ((args.chroot && chroot(args.chroot)==-1) ||
This page took 0.029327 seconds and 4 git commands to generate.