Fri Jan 27 18:02:09 2017 UTC ()
Strip first otherwise we end up with __RCSID("NetBSD")


(christos)
diff -r1.6 -r1.7 src/crypto/external/bsd/heimdal/heimdal2netbsd

cvs diff -r1.6 -r1.7 src/crypto/external/bsd/heimdal/heimdal2netbsd (expand / switch to unified diff)

--- src/crypto/external/bsd/heimdal/heimdal2netbsd 2014/04/22 14:07:31 1.6
+++ src/crypto/external/bsd/heimdal/heimdal2netbsd 2017/01/27 18:02:09 1.7
@@ -1,16 +1,16 @@ @@ -1,16 +1,16 @@
1#! /bin/sh 1#! /bin/sh
2# 2#
3# $NetBSD: heimdal2netbsd,v 1.6 2014/04/22 14:07:31 pettai Exp $ 3# $NetBSD: heimdal2netbsd,v 1.7 2017/01/27 18:02:09 christos Exp $
4# 4#
5# Copyright (c) 2011 The NetBSD Foundation, Inc. 5# Copyright (c) 2011 The NetBSD Foundation, Inc.
6# All rights reserved. 6# All rights reserved.
7# 7#
8# Redistribution and use in source and binary forms, with or without 8# Redistribution and use in source and binary forms, with or without
9# modification, are permitted provided that the following conditions 9# modification, are permitted provided that the following conditions
10# are met: 10# are met:
11# 1. Redistributions of source code must retain the above copyright 11# 1. Redistributions of source code must retain the above copyright
12# notice, this list of conditions and the following disclaimer. 12# notice, this list of conditions and the following disclaimer.
13# 2. Redistributions in binary form must reproduce the above copyright 13# 2. Redistributions in binary form must reproduce the above copyright
14# notice, this list of conditions and the following disclaimer in the 14# notice, this list of conditions and the following disclaimer in the
15# documentation and/or other materials provided with the distribution. 15# documentation and/or other materials provided with the distribution.
16# 16#
@@ -174,36 +174,36 @@ for f in $d/lib/sl/slc-gram.y $d/lib/com @@ -174,36 +174,36 @@ for f in $d/lib/sl/slc-gram.y $d/lib/com
174 sed -E -e "s,(.#include <)($KRB5_INCRE)\\.h>,\\1krb5/\\2.h>," \ 174 sed -E -e "s,(.#include <)($KRB5_INCRE)\\.h>,\\1krb5/\\2.h>," \
175 < $f > /tmp/heimdal1f$$ && mv /tmp/heimdal1f$$ $f && \ 175 < $f > /tmp/heimdal1f$$ && mv /tmp/heimdal1f$$ $f && \
176 echo fixing include paths in $f 176 echo fixing include paths in $f
177done 177done
178 178
179# Freeze imported NetBSD RCSID's. 179# Freeze imported NetBSD RCSID's.
180find $d -type f -print | xargs egrep -l '\$NetBSD:' | while read f; do 180find $d -type f -print | xargs egrep -l '\$NetBSD:' | while read f; do
181 sed \ 181 sed \
182 -e 's/\$\(NetBSD.*\) \$/\1/' \ 182 -e 's/\$\(NetBSD.*\) \$/\1/' \
183 < $f > /tmp/heimdal1f$$ && mv /tmp/heimdal1f$$ $f && \ 183 < $f > /tmp/heimdal1f$$ && mv /tmp/heimdal1f$$ $f && \
184 echo froze NetBSD RCSID for $f 184 echo froze NetBSD RCSID for $f
185done 185done
186 186
 187### Remove the $'s around RCS tags
 188cleantags $d
 189
187# Convert unexpanded RCSID's to the NetBSD way. 190# Convert unexpanded RCSID's to the NetBSD way.
188find $d -type f -print | xargs egrep -l 'RCSID\("\$Id\$"\)' | while read f; do 191find $d -type f -print | xargs egrep -l 'RCSID\("Id"\)' | while read f; do
189 sed -e 's/RCSID("\$\Id\$")/__RCSID("\$NetBSD\$")/' \ 192 sed -e 's/RCSID("Id")/__RCSID("\$NetBSD\$")/' \
190 < $f > /tmp/heimdal1f$$ && mv /tmp/heimdal1f$$ $f && \ 193 < $f > /tmp/heimdal1f$$ && mv /tmp/heimdal1f$$ $f && \
191 echo converted RCSID to NetBSD for $f 194 echo converted RCSID to NetBSD for $f
192done 195done
193 196
194### Remove the $'s around RCS tags 
195cleantags $d 
196 
197### Add our NetBSD RCS Id 197### Add our NetBSD RCS Id
198find $d -type f -name '*.[chly]' -print | while read c; do 198find $d -type f -name '*.[chly]' -print | while read c; do
199 sed 1q < $c | grep -q '\$NetBSD' || ( 199 sed 1q < $c | grep -q '\$NetBSD' || (
200echo "/* \$NetBSD\$ */" >/tmp/${prog}3n$$ 200echo "/* \$NetBSD\$ */" >/tmp/${prog}3n$$
201echo "" >>/tmp/${prog}3n$$ 201echo "" >>/tmp/${prog}3n$$
202cat $c >> /tmp/${prog}3n$$ 202cat $c >> /tmp/${prog}3n$$
203mv /tmp/${prog}3n$$ $c && echo added NetBSD RCS tag to $c 203mv /tmp/${prog}3n$$ $c && echo added NetBSD RCS tag to $c
204 ) 204 )
205done 205done
206 206
207find $d -type f -name '*.[0-9]' -print | while read m; do 207find $d -type f -name '*.[0-9]' -print | while read m; do
208 sed 1q < $m | grep -q '\$NetBSD' || ( 208 sed 1q < $m | grep -q '\$NetBSD' || (
209echo ".\\\" \$NetBSD\$" >/tmp/${prog}2m$$ 209echo ".\\\" \$NetBSD\$" >/tmp/${prog}2m$$