Exhibit 10.4 


 





EXECUTION VERSION


 


AMENDMENT NO. 1 TO GUARANTY AGREEMENT


 


AMENDMENT NO. 1 TO GUARANTY AGREEMENT, dated
June 22, 2012 (this “Amendment”), is by and among Wells Fargo Capital Finance, LLC, formerly known as Wells Fargo Foothill,
LLC, a Delaware limited liability company, in its capacity as administrative agent and co-collateral agent pursuant to the Loan
Agreement (as hereinafter defined) acting for and on behalf of the parties thereto as lenders (in such capacity, “Agent”),
NCI Group, Inc., a Nevada corporation (“NCI”), Robertson-Ceco II Corporation, a Delaware corporation (“Robertson-Ceco”,
and together with NCI, each individually, a “Borrower” and collectively, “Borrowers”), NCI Building Systems,
Inc., a Delaware corporation (“NCI Building Systems” or “Parent”) and Steelbuilding.com, Inc., a Delaware
corporation (“Steelbuilding” and together with Parent and Borrowers, each individually a “Guarantor” and
collectively, “Guarantors”).


 


WITNESSETH:


 


WHEREAS, Agent, Borrowers and Guarantors
have entered into financing arrangements pursuant to which Lenders (or Agent on behalf of Lenders) have made and may make loans
and advances and provide other financial accommodations to Borrowers as set forth in the Loan and Security Agreement, dated October
20, 2009, by and among Agent, Lenders, Borrowers, Guarantors and the other agents named therein (as amended by Amendment No. 1
to the Loan and Security Agreement, dated December 3, 2010, and Amendment No. 2 to the Loan and Security Agreement, dated May 2,
2012, and as the same may hereafter be further amended, modified, supplemented, extended, renewed, restated
or replaced, the “Loan Agreement”) and the other Financing Agreements;


 


WHEREAS, Guarantors have guaranteed certain
obligations of the Borrowers and Parent under the Loan Agreement pursuant to that certain Guaranty Agreement dated as of October
20, 2009 (the “ABL Guaranty”), among Guarantors and ABL Agent;


 


WHEREAS, Guarantors desire to amend certain
provisions of the ABL Guaranty as set forth herein, and Agent is willing to agree to such amendments on the terms and subject to
the conditions set forth herein; and


 


WHEREAS, by this Amendment, Agent and Guarantors
desire and intend to evidence such amendments;


 


NOW THEREFORE, in consideration of the foregoing
and the mutual agreements and covenants contained herein, and other good and valuable consideration, the receipt and sufficiency
of which are hereby acknowledged, the parties hereto agree as follows:


 


1.          Amendment
to ABL Guaranty. The ABL Guaranty is, effective as of the satisfaction of the conditions precedent set forth in Section
3 below, hereby amended by deleting the initial paragraph thereof in its entirety and replacing it with the following:


 



    	 



    	 



    

 


“THIS GUARANTY AGREEMENT, dated
October 20, 2009 (as amended, modified, supplemented, extended, renewed, restated or replaced,
the “Guaranty”) is by NCI Group, Inc., a Nevada corporation (“NCI”), Robertson-Ceco II Corporation, a Delaware
corporation (“Ceco” and, collectively with NCI and each other Borrower (as such term is defined in the Loan Agreement,
as hereinafter defined) under the Loan Agreement from time to time, each individually a “Borrower” and collectively
the “Borrowers”), NCI Building Systems, Inc., a Delaware corporation (“Company”) and Steelbuilding.com,
Inc., a Delaware corporation (“Steelbuilding”), in favor of Wells Fargo Capital Finance, LLC, a Delaware limited liability
company, in its capacity as administrative agent and collateral agent for the Secured Parties, as such term is defined in the Loan
Agreement, (in such capacity, “Agent”). The Company, Ceco, NCI, Steelbuilding and any other Subsidiary of the Company
that becomes party hereto after the date hereof in accordance with Section 17 hereof are sometimes hereinafter referred to hereunder
individually each, as a “Guarantying Party” and collectively, as “Guarantying Parties”.”


 


2.          Interpretation.
For purposes of this Amendment, all terms used herein which are not otherwise defined herein, including but not limited to, those
terms used in the recitals hereto, shall have the respective meanings assigned thereto in the Loan Agreement.


 


3.          Conditions
Precedent. The amendment contained herein shall only be effective on the date on which each of the following conditions precedent
are satisfied in a manner reasonably satisfactory to Agent (the “Amendment Effective Date”):


 


(a)          Agent
shall have received counterparts of this Amendment, duly authorized, executed and delivered by Borrowers and Guarantors;
and


 


(b)          Agent
shall have received the consent or authorization from such Lenders as are required for the amendments provided for herein to execute
this Amendment on behalf of the Lenders.


 


Agent will promptly confirm the occurrence
of the Amendment Effective Date in writing to Parent.


 


4.          Effect
of this Amendment. Except as expressly set forth herein, no other amendments, changes or modifications to the Financing Agreements
are intended or implied, and in all other respects the Financing Agreements are hereby specifically ratified, restated and confirmed
by all parties hereto as of the effective date hereof and Borrowers and Guarantors shall not be entitled to any other or further
amendment by virtue of the provisions of this Amendment or with respect to the subject matter of this Amendment. To the extent
of conflict between the terms of this Amendment and the other Financing Agreements, the terms of this Amendment shall control.
The ABL Guaranty and this Amendment shall be read and construed as one agreement. On and after the date
that all conditions set forth in Section 3, above, shall have been satisfied and this Amendment
has become effective, each reference in the ABL Guaranty to “this Guaranty”, “hereunder”, “hereof”,
“herein” or words of like import, and each reference in the other Financing Agreements to the ABL Guaranty, shall mean
and be a reference to the ABL Guaranty as amended hereby.


 


5.          Governing
Law. The validity, interpretation and enforcement of this Amendment and any dispute arising out of the relationship between
the parties hereto whether in contract, tort, equity or otherwise, shall be governed by the internal laws of the State of New York
but excluding any principles of conflicts of law or other rule of law that would cause the application of the law of any jurisdiction
other than the laws of the State of New York.


 



    	-2-



    	 



    

  


6.          Binding
Effect. This Amendment shall be binding upon and inure to the benefit of each of the parties hereto and their respective successors
and assigns.


 


7.          Entire
Agreement. This Amendment represents the entire agreement and understanding concerning the subject matter hereof among the
parties hereto, and supersedes all other prior agreements, understandings, negotiations and discussions, representations, warranties,
commitments, proposals, offers and contracts concerning the subject matter hereof, whether oral or written.


 


8.          Headings.
The headings listed herein are for convenience only and do not constitute matters to be construed in interpreting this Amendment.


 


9.          Counterparts.
This Amendment may be executed in any number of counterparts, each of which shall be an original, but all of which taken together
shall constitute one and the same agreement. Delivery of an executed counterpart of this Amendment by telefacsimile or other electronic
method of transmission shall have the same force and effect as delivery of an original executed counterpart of this Amendment.
Any party delivering an executed counterpart of this Amendment by telefacsimile or other electronic method of transmission shall
also deliver an original executed counterpart of this Amendment, but the failure to do so shall not affect the validity, enforceability,
and binding effect of this Amendment.


 


[REMAINDER OF THIS PAGE INTENTIONALLY
LEFT BLANK]


  



    	-3-



    	 



    

 


IN WITNESS WHEREOF, the parties hereto have
caused this Amendment to be duly executed and delivered by their authorized officers as of the day and year first above written.


 


	WELLS FARGO CAPITAL

 FINANCE, LLC, as Administrative

Agent
	 
	By:	/s/ Matt Mouledous	 
	Name:	Matt Mouledous	 
	Title:	VP	 





 


[SIGNATURES CONTINUED ON NEXT PAGE]


 



    	 



    	 



    

 


[SIGNATURES CONTINUED FROM PREVIOUS PAGE]





 


	 	NCI GROUP, INC
	 	 
	 	By:	/s/ Mark Johnson
	 	Name:	Mark Johnson
	 	Title:	Executive Vice President, Chief
	 	 	Financial Officer and Treasurer
	 	 
	 	ROBERTSON-CECO II CORPORATION
	 	 
	 	By:	/s/ Mark Johnson
	 	Name:	Mark Johnson
	 	Title:	Executive Vice President, Chief
	 	 	Financial Officer and Treasurer
	 	 
	 	NCI BUILDING SYSTEMS, INC.
	 	 
	 	By:	/s/ Mark Johnson
	 	Name:	Mark Johnson
	 	Title:	Executive Vice President, Chief
	 	 	Financial Officer and Treasurer
	 	 
	 	STEELBUILDING.COM INC.
	 	 
	 	By:	/s/ Mark Johnson
	 	Name:	Mark Johnson
	 	Title:	Vice President - Accounting