from Ffs import Ffs\r
import os\r
from CommonDataClass.FdfClass import DataSectionClassObject\r
+from Common.Misc import PeImageClass\r
import shutil\r
\r
## generate data section\r
(os.path.getmtime(MapFile) > os.path.getmtime(CopyMapFile)):\r
shutil.copyfile(MapFile, CopyMapFile)\r
\r
+ #Get PE Section alignment when align is set to AUTO\r
+ if self.Alignment == 'Auto' and self.SecType in ('TE', 'PE32'):\r
+ ImageObj = PeImageClass (Filename)\r
+ if ImageObj.SectionAlignment < 0x400:\r
+ self.Alignment = str (ImageObj.SectionAlignment)\r
+ else:\r
+ self.Alignment = str (ImageObj.SectionAlignment / 0x400) + 'K'\r
+\r
NoStrip = True\r
if self.SecType in ('TE', 'PE32'):\r
if self.KeepReloc != None:\r