## @file\r
# section base class\r
#\r
-# Copyright (c) 2007-2014, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2007-2015, Intel Corporation. All rights reserved.<BR>\r
#\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
Makefile = os.path.join(MakefileDir, 'Makefile')\r
if not os.path.exists(Makefile):\r
Makefile = os.path.join(MakefileDir, 'GNUmakefile')\r
- if not os.path.exists(Makefile):\r
- SuffixMap = FfsInf.GetFinalTargetSuffixMap()\r
- if Suffix in SuffixMap:\r
- FileList.extend(SuffixMap[Suffix])\r
- else:\r
+ if os.path.exists(Makefile):\r
# Update to search files with suffix in all sub-dirs.\r
Tuple = os.walk(FfsInf.EfiOutputPath)\r
for Dirpath, Dirnames, Filenames in Tuple:\r
FullName = os.path.join(Dirpath, F)\r
if os.path.getmtime(FullName) > os.path.getmtime(Makefile):\r
FileList.append(FullName)\r
-\r
+ if not FileList:\r
+ SuffixMap = FfsInf.GetFinalTargetSuffixMap()\r
+ if Suffix in SuffixMap:\r
+ FileList.extend(SuffixMap[Suffix])\r
+ \r
#Process the file lists is alphabetical for a same section type\r
if len (FileList) > 1:\r
FileList.sort()\r