]> git.pld-linux.org Git - packages/rpm-build-tools.git/blobdiff - adapter.awk
- change @ to # when doing tags
[packages/rpm-build-tools.git] / adapter.awk
index d4fef6dd64e4fd39db9a265f2070f8dac81bd0d2..ea72b3fec65100435fb8d0cd9f7d1982d5fb0e94 100644 (file)
@@ -514,7 +514,7 @@ function fixedsub(s1,s2,t,      ind) {
 function format_preamble()
 {
        sub(/:[ \t]*/, ":")
-       if (match($0, /[A-Za-z0-9()#_ \t]+[ \t]*:[ \t]*/) == 1) {
+       if (match($0, /[A-Za-z0-9(),#_ \t]+[ \t]*:[ \t]*/) == 1) {
                if (RLENGTH < 8)
                        sub(/:/, ":\t\t")
                else
@@ -546,7 +546,7 @@ function use_macros()
                gsub("%{_prefix}/lib", "%{_libdir}")
 
        for (c = 1; c <= NF; c++) {
-               if ($c ~ sysconfdir "/{?cron.d")
+               if ($c ~ sysconfdir "/{?cron.")
                        continue;
                if ($c ~ sysconfdir "/{?crontab.d")
                        continue;
@@ -589,7 +589,9 @@ function use_macros()
        gsub("%{prefix}/info", "%{_infodir}")
        gsub("%{_prefix}/info", "%{_infodir}")
 
-       gsub("%{_datadir}/aclocal", "%{_aclocaldir}")
+       if (prefix !~ "/X11R6") {
+               gsub("%{_datadir}/aclocal", "%{_aclocaldir}")
+       }
 
        if (prefix != "/") {
                for (c = 1; c <= NF; c++) {
@@ -603,8 +605,11 @@ function use_macros()
        gsub("%{PACKAGE_VERSION}", "%{version}")
        gsub("%{PACKAGE_NAME}", "%{name}")
 
-       gsub("%{_datadir}/gnome/apps", "%{_applnkdir}")
-       gsub("%{_datadir}/applnk", "%{_applnkdir}")
+       # we can move files between tge dirs below
+       if ($0 !~ "%{_applnkdir}") {
+               gsub("%{_datadir}/gnome/apps", "%{_applnkdir}")
+               gsub("%{_datadir}/applnk", "%{_applnkdir}")
+       }
 
        gsub("^make$", "%{__make}")
        gsub("^make ", "%{__make} ")
This page took 0.030876 seconds and 4 git commands to generate.