delivered the opinion of the court.
The controversy is whether the facts created a material-man’s lien upon the buildings and property of the Oregon Railroad & Navigation Company.
For the purpose of aiding mechanics and laborers and materialmen in collecting their compensation for labor and material furnished in the construction of a building or other structure, the statute (Section 5640, B. & C. Comp.) has provided that every person performing labor or furnishing material to be used in the construction of any building or structure shall have a lien upon the same for labor or material furnished at the instance of the owner of the building or his agent.
“And every contractor * * or other person having charge of the construction * * of any building * * shall be held to be the agent of the owner for the purposes of this act.”
Without such a statutory provision the building or the owner of it would not be liable for the debt except upon his contract, and to enable a lien claimant to establish his lien under this law he must connect himself by contract with the owner. This can only be done by showing that the work was performed for the owner, or for a contractor, whom the statute has made the agent of the owner; that is, he must bring himself within the original contract. If the contractor has one contract for the erection of several buildings for one price, even though the buildings are separate from each other, it has been held that he or his subcontractor may have one lien thereunder against all the buildings; but otherwise, where the construction of each building is the subject of a separate contract, neither he nor the subcontractor are entitled to include in one lien all the properties for labor *415or material furnished for their construction and used in the buildings indiscriminately, for the reason that the lien, by the terms of the statute, is upon each building for the labor or material only entering into its construction, except in cases where the owner has treated several structures as one. We deem it unnecessary to enter into any extended discussion of this question, as it is settled in an opinion by Mr. Justice Lord in Willamette Mills Co. v. Shea, 24 Or. 40 (32 Pac. 759), and one by Mr. Justice Wolverton in Beach v. Stamper, 44 Or. 4 (74 Pac. 208: 102 Am. St. Rep. 597), where it is held that the original contract must form the basis for the lien on the whole. “All authority to bind the owner on account of the building or buildings to be constructed must emanate from the original contract, which becomes the foundation law for the government of all subcontracts, as they must be let under it and by virtue of the contractor’s authority obtained through it.” Flanagan Bros. v. O’Connell, 88 Mo. App. 1, and Livermore v. Wright, 33 Mo. 31, cited by plaintiff, are to the same effect. The Premier Steel Co. v. McElwaine Richards Co., 144 Ind. 614 (43 N. E. 876) ; Lindsay v. Gunning, 59 Conn. 296 (22 Atl. 310: 11 L. R. A. 553) ; and Press Brick Co. v. Brick & Quarry Co., 151 Mo. 510 (52 S. W. 401: 74 Am. St. Rep. 557), also cited by plaintiff, are not in point, as they relate to liens based on contracts made directly with the owner, and not through an original contractor.
Plaintiff’s claim of lien is an attempt to hold a lien against the property of the Oregon Railroad & Navigation Company, with whom it has no contract, and it does not connect itself with the owner by or through the original contract.
The decisions of this court in the two cases above cited are decisive of this. The decree is affirmed.
Affirmed.