
329 Md. 300 (1993)
619 A.2d 528
NATIONAL GLASS, INC.
v.
J.C. PENNEY PROPERTIES, INC.
No. 42, September Term, 1992.
Court of Appeals of Maryland.
February 9, 1993.
James E. Williams (Jester and Williams, on brief), Washington, DC, for appellant.
Scott S. Braugh (J.C. Penney Co., Inc., on brief), Dallas, TX and Carlton T. Obecny, Bethesda, for appellee.
Argued before MURPHY, C.J., and ELDRIDGE, RODOWSKY, McAULIFFE, CHASANOW, KARWACKI and ROBERT M. BELL, JJ.
KARWACKI, Judge.
We issued a writ of certiorari in this case to determine a conflicts of law question, namely whether Maryland's statutory prohibition against the waiver of mechanics' lien rights by a subcontractor in an executory contract, as provided by Maryland Code (1974, 1988 Repl.Vol.), § 9-113 of the Real Property Article, is such a fundamental public policy so as to render unenforceable such a waiver in a contract in which the parties have provided that the law of another state should govern its interpretation and enforcement, and under the law chosen by the parties such a waiver is permitted. After hearing argument in this case, we have determined that this appeal is from an unappealable interlocutory judgment, and thus, lacking jurisdiction, we shall dismiss the appeal. A brief summary of the procedural history of this case is in order.

I.
In November 1990, appellant, National Glass, Inc. ("NGI"), entered into a subcontract with a general contractor, John R. Hess, Inc. ("Hess"), relating to the construction of a new department store for appellee, J.C. Penney Properties, Inc. ("Penney"). Penney's new department store was to be constructed at the St. Charles Towne Center located at Waldorf in Charles County.[1]
Under its subcontract with Hess, NGI agreed to provide labor, materials, and supplies in connection with the installation of glass, windows, and doors for the store at a price of $90,000.00. Upon completing its work and after complying with the statutory notice requirement, NGI filed a petition to establish a mechanics' lien on July 19, 1991, in the Circuit Court for Charles County, seeking a lien in the amount of $56,579.00.[2]
On July 26, 1991, a Show Cause Order was issued by Judge George W. Bowling of the Circuit Court for Charles County. See § 9-106; Maryland Rule BG 73. A show cause hearing was scheduled for September 4, 1991. Prior to the show cause hearing, Penney moved to dismiss NGI's petition to establish a mechanics' lien challenging both NGI's compliance with the statutory notice requirements and the applicability of an arbitration clause in NGI's subcontract with Hess. At the show cause hearing on September 4, 1991, Penney further asserted that NGI, in paragraph 12.1 of its subcontract with Hess, waived its right to file a mechanics' lien. Paragraph 12.1 of the subcontract provides:
"Subcontractor hereby waives and releases all liens or right of liens now existing or that may hereafter arise for any and all work or labor performed or material furnished under this Subcontract, upon said facility, or monies due or to become due to Contractor, and agrees to furnish a good and sufficient waiver of lien in proper form for filing from every person or entity furnishing labor or materials for this Project under Subcontractor."
Notwithstanding paragraph 12.1 of the subcontract, NGI asserted that, by prior correspondence, it had expressly refused to waive its right to establish any future mechanics' liens that might arise from construction of the department store. Although no testimony was received by the circuit court, NGI asserted that, before the subcontract was signed, it had mailed a letter to Hess stating that it refused to waive its mechanics' lien rights. NGI further asserted that Hess accepted this proviso by initialing the letter and sending it back to NGI. Following argument from both NGI and Penney, the circuit court in an oral opinion dismissed NGI's petition to establish a mechanics' lien on the ground that the petition failed to state a claim upon which relief could be granted. See Md.Rule 2-322(b). The Circuit Court stated:
"I don't think we can go forward until the pleadings assert a claim on which you are entitled to relief. And a pleading which has attached to it a contract which says that the party who agrees to do the work will not assert a lien against the property certainly would preclude one from obtaining a lien as authorized under the statute. The contract itself says that he waives his right to assert any claim to a lien against the property."
Prior to conclusion of the hearing, NGI requested and was granted leave to amend its petition by September 20, 1991. On September 6, 1991, two days after the show cause hearing, instead of amending its petition, NGI filed a motion for reconsideration, asserting that § 9-113 of the Real Property Article rendered the lien waiver provision contained in paragraph 12.1 of the contract void.[3]
Penney opposed the motion for reconsideration, asserting that Maryland law was not controlling. Rather, Penney contended that the subcontract contained a choice of law provision in paragraph 15.9 by which Pennsylvania law was controlling, and under the law of that state, the waiver of lien rights in paragraph 12.1 was valid.[4]
On September 26, 1991, the circuit court denied NGI's motion for reconsideration, and NGI appealed that denial to the Court of Special Appeals. We issued our writ of certiorari in this case to the intermediate appellate court prior to argument in that court.

II.
As a general rule an appeal will lie only from a final judgment. Md.Code (1974, 1989 Repl.Vol.), § 12-301 of the Courts and Judicial Proceedings Article. It is well settled that the dismissal of a complaint for failure to state a cause of action with leave to amend is not an appealable final judgment. Makovi v. Sherwin-Williams Co., 311 Md. 278, 281, 533 A.2d 1303, 1305 (1987); Central Collection Unit v. Columbia Medical Plan, 300 Md. 318, 323-24, 478 A.2d 303, 305 (1984); Griffin v. Board of Trustees of Saint Mary's College, 258 Md. 276, 279, 265 A.2d 757, 759 (1970); Porter v. Bingham, 257 Md. 213, 215, 262 A.2d 498, 499 (1970); Read Drug & Chemical Co. v. Colwill Constr. Co., Inc., 250 Md. 406, 422, 243 A.2d 548, 558 (1968); Evans v. Shiloh Baptist Church, Inc., 196 Md. 543, 551, 77 A.2d 160, 163-64 (1950). Judge Eldridge speaking for the Court in Makovi v. Sherwin-Williams Co., supra, stated the principles which, in the context of this case, are both appropriate and dispositive.
"If the circuit court's order of [September 4, 1991,] had not contained the provision for leave to file an amended [petition by September 20, 1991, the September 4th] order would have been final and appealable. Nevertheless, the express provision for amendment shows that the [September 4th order dismissing NGI's petition to establish a mechanics' lien] was not intended finally to dispose of the case; thus the order was not final and appealable. Consequently, the ... appeal was premature."
311 Md. at 281-82, 533 A.2d at 1305 (citations omitted). An issue similar to the instant case was presented in Griffin v. Board of Trustees of Saint Mary's College, supra. The trial judge sustained a demurrer and granted Griffin 15 days leave to amend. 258 Md. at 279, 265 A.2d at 758. Griffin did not amend, but did appeal within 30 days. Id. We dismissed the appeal because the judgment appealed from was not final. Id. We stated: "That Griffin allowed the time within which he could have amended to expire without taking any action does not improve his position." Id., 265 A.2d at 759.
In short, because this appeal was taken from an unappealable interlocutory judgment, the appeal is dismissed.
APPEAL DISMISSED. COSTS TO BE PAID BY THE APPELLANT.
NOTES
[1]  The record indicates that this case is one of several lawsuits arising out of the construction of the department store. During construction of the department store, Hess abandoned the job site. Penney filed suit against Hess in the United States District Court for the District of Maryland on July 8, 1991. J.C. Penny Properties, Inc. v. John R. Hess, Inc., et al., No. JH-91-1910. Among the counts in that suit is one alleging fraudulent retention of trust funds resulting from the failure of Hess to pay its subcontractors. See Maryland Code (1974, 1988 Repl.Vol., 1992 Supp.), §§ 9-201 to 9-204 of the Real Property Article. The record also indicates other suits relating to the construction of the department store are pending in various courts.
[2]  In Maryland, mechanics' liens are governed by Md.Code (1974, 1988 Repl.Vol., 1992 Supp.), §§ 9-101 to 9-114 of the Real Prop. Art. and Maryland Rules BG 70 through BG 77. Section 9-104 provides that a subcontractor is not entitled to a mechanics' lien unless, within 90 days after doing the work or furnishing the materials, the subcontractor gives the owner written notice of an intention to claim a lien. The notice is required for the protection of the owner of the property. Himelfarb v. B & M Welding & Iron Works, Inc., 254 Md. 37, 42, 253 A.2d 842, 844 (1969). On receipt of the notice, the owner is afforded an opportunity to withhold, from the sums due the contractor, the amount the owner ascertains to be due the subcontractor. Id.; § 9-104(f).
[3]  Section 9-113 provides:

"(a) In general.  An executory contract between a contractor and any subcontractor that is related to construction, alteration, or repair of a building, structure, or improvement may not waive or require the subcontractor to waive the right to:
(1) Claim a mechanics' lien; or
(2) Sue on a contractor's bond.
"(b) Provisions void.  Any waiver provision of a contract made in violation of this section is void."
[4]  Paragraph 15.9 provides:

"This subcontract shall be governed by and interpreted in accordance with the laws of the Commonwealth of Pennsylvania; and shall be binding on the parties, their successors and assigns."
It is undisputed that under Pennsylvania law mechanics' liens may be waived at any time. See Pa. Stat. Ann. tit. 49, § 1401 (Purdon 1965).
"A contractor or subcontractor may waive his right to file a claim by a written instrument signed by him or by any conduct which operates equitably to estop such contractor or subcontractor from filing a claim."
Id.; see also McLaughlin v. Gwynedd Pike Assocs., 368 Pa.Super. 358, 534 A.2d 122 (Pa. Super. Ct. 1987).
