[Scripts]: rename caravel_out to caravel + copy caravel.gds to caravel.old.gds before generating GDS
diff --git a/Makefile b/Makefile
index 4513822..525b3f8 100644
--- a/Makefile
+++ b/Makefile
@@ -21,6 +21,7 @@
@echo "###############################################"
@echo "Generating Caravel GDS (sources are in the 'gds' directory)"
@sleep 1
+ @cp gds/caravel.gds gds/caravel.old.gds && echo "Copying old Caravel to gds/caravel.old.gds" || true
@cd gds && MAGTYPE=mag magic -rcfile ${PDK_ROOT}/sky130A/libs.tech/magic/current/sky130A.magicrc -noc -dnull gen_caravel.tcl < /dev/null
diff --git a/gds/gen_caravel.tcl b/gds/gen_caravel.tcl
index c4ec3e1..eadca1d 100644
--- a/gds/gen_caravel.tcl
+++ b/gds/gen_caravel.tcl
@@ -1,3 +1,14 @@
+# Copyright 2020 Efabless Corporation
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+# http://www.apache.org/licenses/LICENSE-2.0
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
drc off
gds readonly true
gds rescale false
@@ -28,10 +39,10 @@
property GDS_START ""
property GDS_END ""
-save caravel_out
+save caravel
select top cell
# cif *hier write disable
-gds write caravel_out.gds
+gds write caravel.gds