OpenCores
URL https://opencores.org/ocsvn/openarty/openarty/trunk

Subversion Repositories openarty

[/] [openarty/] [trunk/] [mkdatev.pl] - Blame information for rev 5

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 5 dgisselq
#!/usr/bin/perl
2
################################################################################
3
##
4
## Filename:    mkdatev.pl
5
##
6
## Project:     OpenArty, an entirely open SoC based upon the Arty platform
7
##
8
## Purpose:     This file creates a file containing a `define DATESTAMP
9
##              which can be used to tell when the build took place.
10
##
11
##
12
## Creator:     Dan Gisselquist, Ph.D.
13
##              Gisselquist Technology, LLC
14
##
15
################################################################################
16
##
17
## Copyright (C) 2016, Gisselquist Technology, LLC
18
##
19
## This program is free software (firmware): you can redistribute it and/or
20
## modify it under the terms of  the GNU General Public License as published
21
## by the Free Software Foundation, either version 3 of the License, or (at
22
## your option) any later version.
23
##
24
## This program is distributed in the hope that it will be useful, but WITHOUT
25
## ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY or
26
## FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
27
## for more details.
28
##
29
## License:     GPL, v3, as defined and found on www.gnu.org,
30
##              http:##www.gnu.org/licenses/gpl.html
31
##
32
##
33
################################################################################
34
##
35
##
36
 
37
$now = time;
38
($sc,$mn,$nhr,$ndy,$nmo,$nyr,$nwday,$nyday,$nisdst) = localtime($now);
39
$nyr = $nyr+1900; $nmo = $nmo+1;
40
 
41
# And just because perl doesn't like my dollars signs ...
42
$doc = "\$(ROOT)/doc";
43
 
44
print <<"EOM";
45
////////////////////////////////////////////////////////////////////////////////
46
//
47
// Filename:    builddate.v
48
//
49
// Project:     OpenArty, an entirely open SoC based upon the Arty platform
50
//
51
// Purpose:     This file records the date of the last build.  Running "make"
52
//              in the main directory will create this file.  The `define found
53
//      within it then creates a version stamp that can be used to tell which
54
//      configuration is within an FPGA and so forth.
55
//
56
// Creator:     Dan Gisselquist, Ph.D.
57
//              Gisselquist Technology, LLC
58
//
59
////////////////////////////////////////////////////////////////////////////////
60
//
61
// Copyright (C) 2015-2016, Gisselquist Technology, LLC
62
//
63
// This program is free software (firmware): you can redistribute it and/or
64
// modify it under the terms of  the GNU General Public License as published
65
// by the Free Software Foundation, either version 3 of the License, or (at
66
// your option) any later version.
67
//
68
// This program is distributed in the hope that it will be useful, but WITHOUT
69
// ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY or
70
// FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
71
// for more details.
72
//
73
// You should have received a copy of the GNU General Public License along
74
// with this program.  (It's in the $doc directory, run make with no
75
// target there if the PDF file isn't present.)  If not, see
76
// <http://www.gnu.org/licenses/> for a copy.
77
//
78
// License:     GPL, v3, as defined and found on www.gnu.org,
79
//              http://www.gnu.org/licenses/gpl.html
80
//
81
//
82
////////////////////////////////////////////////////////////////////////////////
83
//
84
//
85
EOM
86
 
87
print "`define DATESTAMP 32\'h";
88
printf("%04d%02d%02d\n", $nyr, $nmo, $ndy);
89
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.