Commit 06242b6a authored by unknown's avatar unknown

Resolve a possible timing issue with "scripts/mysql_fix_privilege_tables_sql.c" in the

source tarball, this is essential for cross builds, like for NetWare.


scripts/Makefile.am:
  On a fast build machine, both the source (mysql_fix_privilege_tables.sql) 
  and the generated file (mysql_fix_privilege_tables_sql.c) may have identical timestamps
  (granularity is one second only, may be too coarse).
  If that happens, the Makefile rule will fire, and "comp_sql" will be built and called -
  which fails in a cross build, like for NetWare.
  
  Prevent that by sleeping for 5 (five) seconds, this will ensure a time difference.
parent b9266843
...@@ -122,9 +122,11 @@ mysql_fix_privilege_tables.sql: mysql_system_tables.sql \ ...@@ -122,9 +122,11 @@ mysql_fix_privilege_tables.sql: mysql_system_tables.sql \
# #
# Build mysql_fix_privilege_tables_sql.c from # Build mysql_fix_privilege_tables_sql.c from
# mysql_fix_privileges_tables.sql using comp_sql # mysql_fix_privileges_tables.sql using comp_sql
# The "sleep" ensures the generated file has a younger timestamp than its source.
# #
mysql_fix_privilege_tables_sql.c: comp_sql.c mysql_fix_privilege_tables.sql mysql_fix_privilege_tables_sql.c: comp_sql.c mysql_fix_privilege_tables.sql
$(MAKE) $(AM_MAKEFLAGS) comp_sql$(EXEEXT) $(MAKE) $(AM_MAKEFLAGS) comp_sql$(EXEEXT)
sleep 5
$(top_builddir)/scripts/comp_sql$(EXEEXT) \ $(top_builddir)/scripts/comp_sql$(EXEEXT) \
mysql_fix_privilege_tables \ mysql_fix_privilege_tables \
$(top_srcdir)/scripts/mysql_fix_privilege_tables.sql $@ $(top_srcdir)/scripts/mysql_fix_privilege_tables.sql $@
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment