<PAGE>   1
                                                                 EXHIBIT 10.18.5

                                 THIRD AMENDMENT
                       TO SECOND RESTATED CREDIT AGREEMENT


         This Third Amendment to Second Restated Credit Agreement (this "Third
Amendment"), dated as of March 18, 1998, is entered into among Cameron Ashley
Building Products, Inc., a Georgia corporation, Wm. Cameron & Co., a Georgia
corporation, Ashley Aluminum, Inc., a Georgia corporation, CABP, Inc., an
Arizona corporation, Cameron Ashley Canada, Inc., a Canadian corporation,
NationsBank of Texas, National Association, as Issuing Bank and Agent, ABN AMRO
Bank, N.V., as Co-Agent, Canadian Imperial Bank of Commerce, as Canadian Issuing
Bank and Canadian Agent, and each Lender.

                                   BACKGROUND

         Borrowers, Agent, Co-Agent, Issuing Bank, Canadian Agent, Canadian
Issuing Bank and Lenders have entered into the Second Restated Credit Agreement
dated as of January 29, 1997 (such agreement, together with all amendments and
restatements thereof, the "Credit Agreement"). Borrower has requested that
Lenders, Agent, Issuing Bank, Co-Agent, Canadian Agent and Canadian Issuing Bank
amend the Credit Agreement to, among other things, modify certain covenants.

                                    AGREEMENT

         NOW, THEREFORE, in consideration of the covenants, conditions and
agreements hereafter set forth, and for other good and valuable consideration,
the receipt and adequacy of which are all hereby acknowledged, Borrowers, Agent,
Co-Agent, Issuing Bank, Canadian Agent, Canadian Issuing Bank, Lenders and
Guarantors covenant and agree as follows:

1.       Defined Terms.  Capitalized terms used herein and not otherwise
defined herein have the meaning given to them in the Credit Agreement.

2.       Amendments. The Credit Agreement is amended as follows:

         (a)      Section 1.01 is amended by adding the following in
alphabetical order:

                  "Currency Swap (1998)" means the ISDA Agreement dated
         effective March 16, 1998, together with all schedules, between ABN AMRO
         Bank, N.V., Chicago Branch, and CA Canada.

                  "Note Purchase Agreement (1996 Series)" means the Note
         Purchase Agreement dated as of April 1, 1996, among Parent and each
         Senior Holder (1996 Series), as amended by the First Amendment dated as
         of January 15, 1997, among Parent and each Senior Holder (1996 Series).




<PAGE>   2

                  "Note Purchase Agreement (1998 Series)" means each Note
         Purchase Agreement dated as of March 1, 1998, between either Parent or
         CA Canada, respectively, and each Senior Holder (1998 Series).

                  "Senior Holder (1996 Series)" means each Person named on
         Schedule 4.08- a under the "Note Purchase Agreement (1996 Series)"
         heading, and each permitted successor and assign.

                  "Senior Holder (1998 Series)" means each Person named on
         Schedule 4.08- a under the "Note Purchase Agreement (1998 Series)"
         heading, and each permitted successor and assign.

         (b)      The definition of "CAFS Credit Agreement" is deleted, and the
following is substituted in lieu thereof:

                  "CAFS Credit Agreement" means the Restated Credit Agreement
         dated as of January 22, 1998, between CAFS and Bank One, Texas, N.A.,
         as from time to time amended or restated.

         (c)      The definition of "Funded Debt to EBITDA Ratio" is deleted,
and the following is substituted in lieu thereof:

                  "Funded Debt to EBITDA Ratio" means, for any date of
         determination, the ratio of (a) the amount of Funded Debt of Parent and
         its Subsidiaries as at the date of determination, to (b) EBITDA for the
         365-day period ended on the date of determination; provided, (i) with
         respect to any calculation which includes the results for Parent's
         fourth quarter of fiscal 1997, each determination of EBITDA shall have
         added to it, without duplication for any non-cash charges used in such
         determination of "EBITDA", $5,600,000; and (ii) with respect to any
         calculation which includes results for the period beginning on the date
         of issuance of the first note pursuant to the Note Purchase Agreement
         (1998 Series), through June 30, 1998, each determination of Funded Debt
         of Parent and its Subsidiaries shall have deducted from it an amount
         equal to the difference between (y) the amount of all cash of Parent
         and its Subsidiaries (other than CAFS) not subject to any Lien (other
         than Liens in favor of Agent or any Lender or general rights of offset
         in favor of institutions holding such funds), minus (z) $5,000,000.

         (d)      The definition of "Note Purchase Agreement" is deleted, and
the following is substituted in lieu thereof:

                  "Note Purchase Agreement" means each Note Purchase Agreement
         (1996 Series) and each Note Purchase Agreement (1998 Series).



                                       -2-
<PAGE>   3

         (e)      The definition of "Senior Holder" is deleted.

         (f)      Section 3.03 is deleted and the following is substituted in
lieu thereof:

                  3.03 Conditions Precedent to Certain Advances, Letters of
         Credit and Canadian Letters of Credit. The obligation of each Lender to
         make each Advance in excess of United States $75,000,000 (including the
         Initial Advance) and of Issuing Bank or Canadian Issuing Bank to issue
         each Letter of Credit or Canadian Letter of Credit to the extent that
         Borrowers' collective Obligations under this Agreement and the other
         Loan Papers shall in the aggregate exceed United States $75,000,000
         shall be subject to the further condition precedent that on the date of
         such Advance or the issuance of such Letter of Credit or Canadian
         Letter of Credit, the Borrowers shall have received the consent of the
         Senior Holders (1996 Series) holding no less than 66 2/3% of the
         principal amount of the Senior Notes issued pursuant to a Note Purchase
         Agreement (1996 Series) allowing each Guarantor to guarantee the entire
         amount of the Commitment.

         (g)      The second sentence of Section 4.08 is deleted and the
following is substituted in lieu thereof:

                  Schedule 4.08-a is a complete and correct description of each
         Note Purchase Agreement, each Senior Note, each other Senior Note
         Paper, each Senior Holder (1996 Series) and each Senior Holder (1998
         Series).

         (h)      Section 5.07 is deleted and the following is substituted in
lieu thereof:

                  5.07 Debt. Parent and Subsidiaries other than CAFS. Parent
         shall not, and shall not permit any of its Subsidiaries (other than
         CAFS) to, create, incur, assume, become, or be liable in any manner in
         respect of, or suffer to exist, any Debt, except (a) Debt under the
         Loan Papers, (b) Funded Debt under each Note Purchase Agreement and
         guaranties of such Debt made by Parent and Subsidiaries of Parent, (c)
         other Debt in existence on the date hereof, as shown on Schedule
         4.08-a, (d) purchase money Debt incurred for the acquisition of
         tangible assets, provided the aggregate principal amount of such Debt
         incurred in any fiscal year shall not exceed $1,000,000, (e) trade
         payables incurred and paid in the ordinary course of business, (f)
         Contingent Liabilities under or relating to the Loan Papers, (g)
         Contingent Liabilities in existence on the date hereof, as shown on
         Schedule 4.08-a, (h) guarantees by Parent and its Subsidiaries (other
         than CAFS) of obligations in respect of Interest Hedge Agreements
         permitted under Section 5.19, (i) Debt of each Subsidiary of Parent
         (other than CAFS) to Parent or to another Subsidiary of Parent, (j)
         Contingent Liabilities resulting from the endorsement of negotiable
         instruments for collection in the ordinary course of business, (k)
         Convertible Subordinated Debt in an aggregate principal amount not




                                       -3-
<PAGE>   4

         to exceed at any time $25,000,000, (l) as to Parent and its
         Subsidiaries (other than CAFS) on a consolidated basis, other Debt not
         to exceed at any time, in the aggregate principal amount, the
         difference between (i) $10,000,000, minus (ii) the sum of all
         Attributable Debt in respect of all Sale and Leasebacks occurring on
         and after the Effective Date, (m) renewals and restatements of any Debt
         described in Sections 5.07(a) through (l), provided the principal
         amount of the Debt renewed or restated does not exceed the principal
         amount of such Debt immediately prior to such renewal or restatement,
         and (n) as to Parent, only, its obligations under the CAFS Guaranty.

         (i)      Section 5.09 is amended by deleting "and" immediately
preceding "(k)" and by adding the following immediately preceding the period:

                  , and (l) Debt of CAFS payable to Cameron permitted by
         Section 5.20(b).

         (j)      Section 5.18(a) is amended by deleting each "Effective Date"
and substituting "March 1, 1998", in lieu thereof.

         (k)      Section 5.19 is deleted and the following is substituted in
lieu thereof:

                  5.19 Swap Exposure. Parent shall not, and shall not permit any
         of its Subsidiaries to, enter into or become liable in respect of any
         Interest Hedge Agreement other than (a) with respect any Interest Hedge
         Agreement entered into solely to manage risk associated with interest
         to accrue with respect to Funded Debt of Parent or such Subsidiary of
         Parent, Interest Hedge Agreements pursuant to which the aggregate
         notional amount (together with the aggregate notional amount of all
         other Interest Hedge Agreements) does not exceed the aggregate
         principal amount of all Funded Debt, (b) the Currency Swap (1998)
         (excluding any amendment which increases the obligations of CA Canada),
         and (c) other Interest Hedge Agreements entered into by Parent or any
         of its Subsidiaries solely to manage risk associated with interest rate
         and currency value fluctuations (and not for any speculative purpose
         such as making a profit (or incurring a loss) solely as a result of
         interest rate or currency value fluctuations or timing of payments).

         (l)      Section 5.20(b) is deleted and the following is substituted
in lieu thereof:

                  (b) Neither Parent nor any Subsidiary of Parent shall be
         liable at any time for any CAFS Liability or extend credit to or for
         the benefit of CAFS or any CAFS Subsidiary; provided, (i) Parent may
         (A) acquire for cash equity of CAFS (in addition to all equity of CAFS
         owned by Parent on December 3, 1996), and (B) execute and perform under
         the CAFS Guaranty, and (C) make loans to CAFS, or (D) do any
         combination of activities described in clauses (A), (B) and (C), and
         (ii) Cameron may make advances to CAFS, the proceeds of which advances
         will be


                                       -4-
<PAGE>   5

         used by CAFS to pay corporate overhead expenses of CAFS; provided,
         that, the sum of (1) the aggregate gross cash purchase price of equity
         acquired on and prior to December 3, 1996 and pursuant to clause
         (i)(A), plus (2) the aggregate amount for which Parent may be liable
         under the CAFS Guaranty, plus (3) the aggregate amount paid by Parent
         and the fair market value of property of Parent transferred with
         respect to all other CAFS Liabilities, plus (4) the aggregate amount of
         all other liabilities of Parent in respect of CAFS Liabilities (valued
         based on the reasonable determination of Parent (including in such
         valuation the probability of any claim maturing) or, if Agent disagrees
         with any such determination, based on the reasonable determination of
         Agent), plus (5) the aggregate amount of all unpaid principal of and
         accrued interest on all loans made by Parent to CAFS, plus (6) the
         aggregate amount of all unpaid principal of and accrued interest on all
         loans made by Cameron to CAFS, shall not exceed at any time
         $18,500,000; provided, that, Parent may not make or have outstanding
         any loan to or other extension of credit to or for the benefit of CAFS
         if at any time (y) Parent is not the sole owner of all equity and
         rights to acquire any equity of CAFS and (z) Parent does not have a
         perfected, first priority security interest in all Consumer Notes (as
         defined in the CAFS Credit Agreement) which do not qualify as Eligible
         Consumer Notes (as defined in the CAFS Credit Agreement) solely due to
         their non-conformity with the then-applicable requirements related to
         Warehousing Period (as defined in the CAFS Credit Agreement).

         (m)      Schedule 4.08-a is deleted and a new Schedule 4.08-a, in the
form of Schedule 4.08-a to this Third Amendment, is substituted in lieu thereof.

         (n)      Exhibit C is deleted and a new Exhibit C, in the form of
Exhibit A to this Third Amendment, is substituted in lieu thereof.

3.       Representations and Warranties. Borrowers and Guarantors, jointly and
severally, represent and warrant to Agent, Issuing Bank, Co-Agent, Canadian
Agent, Canadian Issuing Bank and each Lender that, as of the date hereof and
after giving effect to the amendments in Section 2, the following are true and
correct:

         (a)      The representations and warranties contained in the Credit
Agreement and each of the other Loan Papers are true and correct in all material
respects on and as of the date hereof as though made on and as of such date
(except as to representations and warranties which (i) refer to a specific date,
(ii) have been modified by transactions permitted pursuant to the Credit
Agreement or any other Loan Paper, or (iii) have been specifically waived in
writing by Agent).

         (b)      Each Borrower and each Guarantor has full power and authority
to execute, deliver and perform this Third Amendment, and this Third Amendment,
the Credit Agreement and each other Loan Paper, constitute the legal, valid and
binding obligation of such Borrower and such



                                       -5-
<PAGE>   6

Guarantor (with respect to Loan Papers to which it is a party), enforceable in
accordance with their terms (subject as to enforcement of remedies to any
applicable Debtor Relief Laws).

         (c)      No authorization, approval, consent or other action by, notice
to, or filing with, any Tribunal or other Person, is required for the execution,
delivery or performance by either Borrower or any Guarantor of this Third
Amendment.

         (d)      No Obligor has made a material misstatement of fact, or failed
to disclose any fact necessary to make the facts disclosed not misleading, to
Agent, Issuing Bank, Co-Agent, Canadian Agent, Canadian Issuing Bank or any
Lender during the course of negotiation of this Third Amendment.

         4.       Conditions of Effectiveness. This Third Amendment shall be
effective on the date Agent delivers to Borrower written notice that each of the
following has occurred or exists ("Amendment Date"):

         (a)      The effectiveness of this Third Amendment shall not contravene
any Law applicable to Agent, Issuing Bank, Co-Agent, Canadian Agent, Canadian
Issuing Bank or any Lender.

         (b)      No Material Adverse Change, as determined by Agent, shall have
occurred and be continuing since December 31, 1997.

         (c)      No Default or Event of Default shall exist.

         (d)      Agent, Issuing Bank, Co-Agent, Canadian Agent, Canadian
Issuing Bank, each Lender and each Obligor shall have executed and received
counterparts of this Third Amendment.

         (e)      Agent shall have received a complete and correct copy of each
of the documents described in Sections 4.1(b), (c), (d) and (e) of the CAFS
Credit Agreement.

         (f)      Agent shall have received a complete and correct copy of the
executed Note Purchase Agreement (1998 Series) and each related note.

         (g)      Agent shall have received a complete and correct copy of the
ISDA Agreement dated effective March 16, 1998, together with all schedules,
between ABN AMRO Bank, N.V., Chicago Branch, and CA Canada and each guaranty and
other agreements assuring the obligations of CA Canada under such agreements.

         (h)      Agent shall have received, contemporaneously with Borrowers'
execution of this Third Amendment, payment of all fees (including attorneys'
fees) incurred by Agent prior to execution of this Third Amendment in the
preparation, negotiation and execution of this Third Amendment.



                                       -6-
<PAGE>   7

         (i)      Agent shall have received, in form and substance satisfactory
to Agent and its counsel, such other approvals, documents, certificates, and
instruments as Agent shall require.

Agent, Issuing Bank, Co-Agent, Canadian Agent, Canadian Issuing Bank and each
Lender may conclusively rely on the certificates delivered pursuant to Section
3.01 of the Credit Agreement until Agent receives notice in writing to the
contrary.

5.       Ratification. Each Borrower and each Guarantor each (a) represents and
warrants that it has received and reviewed this Third Amendment and (b) ratifies
and affirms its obligations under the Loan Papers, as amended by this Third
Amendment.

6.       Reference to the Credit Agreement.

         (a)      On the Amendment Date, each reference in the Credit Agreement
to "this Agreement", "hereunder", or words of like import shall mean and be a
reference to the Credit Agreement, as affected and amended hereby.

         (b)      The Credit Agreement, as affected by the amendments referred
to above, shall remain in full force and effect and is hereby ratified and
confirmed.

         (c)      THE CREDIT AGREEMENT, AS AFFECTED BY THE AMENDMENTS CONTAINED
IN THIS THIRD AMENDMENT, TOGETHER WITH EACH OTHER LOAN PAPER, REPRESENT THE
FINAL AGREEMENT AMONG THE PARTIES AND MAY NOT BE CONTRADICTED BY EVIDENCE OF
PRIOR, CONTEMPORANEOUS OR SUBSEQUENT ORAL AGREEMENTS OF THE PARTIES. THERE ARE
NO UNWRITTEN ORAL AGREEMENTS AMONG THE PARTIES.

7.       Execution in Counterparts. This Third Amendment may be executed in any
number of counterparts and by different parties hereto in separate counterparts,
each of which when so executed and delivered shall be deemed to be an original
and all of which taken together shall constitute but one and the same
instrument.

8.       Governing Law; Binding Effect. This Third Amendment shall be governed
by and construed in accordance with the laws of the State of Texas and be
binding upon the parties hereto and their respective permitted successors and
assigns.

9.       Headings. Section headings in this Third Amendment are included herein
for convenience of reference only and shall not constitute part of this Third
Amendment for any other purpose.



                                       -7-
<PAGE>   8

         IN WITNESS WHEREOF, the parties hereto have executed this Third
Amendment as of March 18, 1998.


PARENT:
                                      CAMERON ASHLEY BUILDING PRODUCTS,
                                      INC.


                                      By: /s/ F. Dixon McElwee
                                         -------------------------------------
                                         F. Dixon McElwee, VP, CFO & Treasurer
                                         -------------------------------------
                                         (Print Name)          (Print Title)


CA CANADA:
                                      CAMERON ASHLEY CANADA, INC.


                                      By: /s/ F. Dixon McElwee
                                         -------------------------------------
                                         F. Dixon McElwee, EVP
                                         -------------------------------------
                                         (Print Name)          (Print Title)


GUARANTORS:
                                      ASHLEY ALUMINUM, INC.


                                      By: /s/ F. Dixon McElwee
                                         -------------------------------------
                                         F. Dixon McElwee, Vice President
                                         -------------------------------------
                                         (Print Name)          (Print Title)


                                      WM. CAMERON & CO.


                                      By: /s/ F. Dixon McElwee
                                         -------------------------------------
                                         F. Dixon McElwee, EVP, CFO & Treasurer
                                         -------------------------------------
                                         (Print Name)          (Print Title)




                                       -8-
<PAGE>   9

                                      CABP, INC.


                                      By: /s/ Ross Goolsby
                                         -------------------------------------
                                         Ross Goolsby       , Vice President
                                         -------------------------------------
                                         (Print Name)          (Print Title)


AGENT:
                                      NATIONSBANK OF TEXAS, NATIONAL
                                      ASSOCIATION


                                      By: /s/ Daniel M. Killian
                                         -------------------------------------
                                         Daniel M. Killian, Vice President


CANADIAN AGENT:
                                      CANADIAN IMPERIAL BANK OF COMMERCE


                                      By: /s/ Terry F. Fraser
                                         -------------------------------------
                                         Terry F. Fraser, Commercial Lending
                                             Specialist
                                         -------------------------------------
                                         (Print Name)          (Print Title)


CO-AGENT:
                                      ABN AMRO BANK, N.V.


                                      By: /s/ Patrick Thom
                                         -------------------------------------
                                         Patrick Thom     , Vice President
                                         -------------------------------------
                                         (Print Name)          (Print Title)


                                      By: /s/ Larry K. Kelley
                                         -------------------------------------
                                         Larry K. Kelley     , Group Vice 
                                             President
                                         -------------------------------------
                                         (Print Name)          (Print Title)




                                       -9-
<PAGE>   10

ISSUING BANK:
                                      NATIONSBANK OF TEXAS, NATIONAL
                                      ASSOCIATION


                                      By: /s/ Daniel M. Killian
                                         -------------------------------------
                                         Daniel M. Killian, Vice President


CANADIAN ISSUING BANK:
                                      CANADIAN IMPERIAL BANK OF COMMERCE


                                      By: /s/ Terry F. Fraser
                                         -------------------------------------
                                         Terry F. Fraser, Commerical Lending
                                                              Specialist
                                         -------------------------------------
                                         (Print Name)          (Print Title)


LENDERS:
                                      NATIONSBANK OF TEXAS, NATIONAL
                                      ASSOCIATION


                                      By: /s/ Daniel M. Killian
                                         -------------------------------------
                                         Daniel M. Killian, Vice President


                                      CANADIAN IMPERIAL BANK OF COMMERCE


                                      By: /s/ Terry F. Fraser
                                         -------------------------------------
                                         Terry F. Fraser, Commercial Lending
                                                              Specialist
                                         -------------------------------------
                                         (Print Name)          (Print Title)




                                      -10-
<PAGE>   11

                                      ABN AMRO BANK, N.V.


                                      By: /s/ Patrick Thom
                                         -------------------------------------
                                         Patrick Thom       , Vice President
                                         -------------------------------------
                                         (Print Name)          (Print Title)


                                      By: /s/ Larry K. Kelley
                                         -------------------------------------
                                         Larry K. Kelley    , Group Vice 
                                             President
                                         -------------------------------------
                                         (Print Name)            (Print Title)


                                      WELLS FARGO BANK (TEXAS), N.A.


                                      By: /s/ Juan T. Sanchez
                                         -------------------------------------
                                         Juan T. Sanchez, Relationship 
                                             Manager
                                         -------------------------------------
                                         (Print Name)          (Print Title)


                                      SUNTRUST BANK, ATLANTA


                                      By: /s/ John A. Fields, Jr.
                                         -------------------------------------
                                         John A. Fields, Jr., Vice President
                                         -------------------------------------
                                         (Print Name)          (Print Title)


                                      By: /s/ John P. Frazer
                                         -------------------------------------
                                         John P. Frazer   , Vice President
                                         -------------------------------------
                                         (Print Name)          (Print Title)





                                      -11-