Click here to Skip to main content
Licence 
First Posted 3 May 2000
Views 41,180
Bookmarked 13 times

Removing debug information from .obj files

By | 3 May 2000 | Article
A small program for removing debug information from object files that aids incrementally linking extremely large projects.
  • Download source files - 4 Kb
  • Introduction

    I'm working on a large project where I found Visual C limits 4095/6 sources with debug information for use in incremental linking. I wanted to remove the debug information from the .obj files that I did not need to step into, so I wrote a quick program.

    This program removes debug information from most .obj files (some cases are not covered, in which the program will not create obj file and will return an error code), which is quicker (minimaly 5-6 times) than creating two .obj files (note that mixing debug and release .obj's is not good idea).

    Usage

    objstrip.exe input.obj output.obj

    Notes

    • Compiling: you MUST use struct member alignment 1 byte!
    • libs: some libs contain not .obj files but .dll's (libraries for comunication with dll/list of exported functions)
    • source: see comments inside source: This program is provided as is with NO guarantee. It works with VC5 and VC6. Improvements are welcomed. It does not work with 100% of objects (ignores more complex mixing of data/code and debug information, see source). It exists for anyone for whom this source is usable. If there is anyone for whom this source is usable then I would love to hear from you.

    License

    This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

    A list of licenses authors might use can be found here

    About the Author

    Tibor Blazko

    Software Developer (Senior)

    Slovakia Slovakia

    Member



    Sign Up to vote   Poor Excellent
    Add a reason or comment to your vote: x
    Votes of 3 or less require a comment

    Comments and Discussions

     
    You must Sign In to use this message board. (secure sign-in)
     
    Search this forum  
     FAQ
        Noise  Layout  Per page   
      Refresh
    GeneralError: IMAGE_SCN_LNK_COMDAT found PinmemberAlexeiKireev21:50 31 Jul '05  
    GeneralRe: Error: IMAGE_SCN_LNK_COMDAT found PinmemberTibor Blazko22:04 31 Jul '05  
    GeneralRe: Error: IMAGE_SCN_LNK_COMDAT found PinmemberAlexeiKireev20:51 2 Aug '05  
    GeneralRe: Error: IMAGE_SCN_LNK_COMDAT found PinmemberTibor Blazko20:54 2 Aug '05  

    General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

    Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

    Permalink | Advertise | Privacy | Mobile
    Web03 | 2.5.120517.1 | Last Updated 4 May 2000
    Article Copyright 2000 by Tibor Blazko
    Everything else Copyright © CodeProject, 1999-2012
    Terms of Use
    Layout: fixed | fluid