See the following statute - I'll post some relevant portions:
Texas Property Code
CHAPTER 53. MECHANIC'S, CONTRACTOR'S, OR MATERIALMAN'S LIEN
SUBCHAPTER B. PERSONS ENTITLED TO LIEN; SUBJECT PROPERTY
Sec. 53.021. PERSONS ENTITLED TO LIEN. (a) A person has a lien if:
(1) the person labors, specially fabricates material, or furnishes labor or materials for construction or repair in this state of:
(A) a house, building, or improvement;
(B) a levee or embankment to be erected for the reclamation of overflow land along a river or creek; or
(C) a railroad; and
(2) the person labors, specially fabricates the material, or furnishes the labor or materials under or by virtue of a contract with the owner or the owner's agent, trustee, receiver, contractor, or subcontractor.
(b) A person who specially fabricates material has a lien even if the material is not delivered.
(c) An architect, engineer, or surveyor who prepares a plan or plat under or by virtue of a written contract with the owner or the owner's agent, trustee, or receiver in connection with the actual or proposed design, construction, or repair of improvements on real property or the location of the boundaries of real property has a lien on the property.
(d) A person who provides labor, plant material, or other supplies for the installation of landscaping for a house, building, or improvement, including the construction of a retention pond, retaining wall, berm, irrigation system, fountain, or other similar installation, under or by virtue of a written contract with the owner or the owner's agent, trustee, or receiver has a lien on the property.
(e) A person who performs labor as part of, or who furnishes labor or materials for, the demolition of a structure on real property under or by virtue of a written contract with the owner of the property or the owner's agent, trustee, receiver, contractor, or subcontractor has a lien on the property.
Sec. 53.022. PROPERTY TO WHICH LIEN EXTENDS. (a) The lien extends to the house, building, fixtures, or improvements, the land reclaimed from overflow, or the railroad and all of its properties, and to each lot of land necessarily connected or reclaimed.
(b) The lien does not extend to abutting sidewalks, streets, and utilities that are public property.
(c) A lien against land in a city, town, or village extends to each lot on which the house, building, or improvement is situated or on which the labor was performed.
(d) A lien against land not in a city, town, or village extends to not more than 50 acres on which the house, building, or improvement is situated or on which the labor was performed.
Sec. 53.023. PAYMENT SECURED BY LIEN. The lien secures payment for:
(1) the labor done or material furnished for the construction or repair;
(2) the specially fabricated material, even if the material has not been delivered or incorporated into the construction or repair, less its fair salvage value; or
(3) the preparation of a plan or plat by an architect, engineer, or surveyor in accordance with Section 53.021(c).
Sec. 53.024. LIMITATION ON SUBCONTRACTOR'S LIEN. The amount of a lien claimed by a subcontractor may not exceed:
(1) an amount equal to the proportion of the total subcontract price that the sum of the labor performed, materials furnished, materials specially fabricated, reasonable overhead costs incurred, and proportionate profit margin bears to the total subcontract price; minus
(2) the sum of previous payments received by the claimant on the subcontract.
Sec. 53.025. LIMITATION ON ORDINARY RETAINAGE LIEN. A lien for retainage is valid only for the amount specified to be retained in the contract, including any amendments to the contract, between the claimant and the original contractor or between the claimant and a subcontractor.
Sec. 53.026. SHAM CONTRACT. (a) A person who labors, specially fabricates materials, or furnishes labor or materials under a direct contractual relationship with another person is considered to be in direct contractual relationship with the owner and has a lien as an original contractor, if:
(1) the owner contracted with the other person for the construction or repair of a house, building, or improvements and the owner can effectively control that person through ownership of voting stock, interlocking directorships, or otherwise;
(2) the owner contracted with the other person for the construction or repair of a house, building, or improvements and that other person can effectively control the owner through ownership of voting stock, interlocking directorships, or otherwise; or
(3) the owner contracted with the other person for the construction or repair of a house, building, or improvements and the contract was made without good faith intention of the parties that the other person was to perform the contract.
(b) In this section, "owner" does not include a person who has or claims a security interest only.
SUBCHAPTER C. PROCEDURE FOR PERFECTING LIEN
Sec. 53.051. NECESSARY PROCEDURES. To perfect the lien, a person must comply with this subchapter.
Sec. 53.052. FILING OF AFFIDAVIT. (a) Except as provided by Subsection (b), the person claiming the lien must file an affidavit with the county clerk of the county in which the property is located or into which the railroad extends not later than the 15th day of the fourth calendar month after the day on which the indebtedness accrues.
(b) A person claiming a lien arising from a residential construction project must file an affidavit with the county clerk of the county in which the property is located not later than the 15th day of the third calendar month after the day on which the indebtedness accrues.
(c) The county clerk shall record the affidavit in records kept for that purpose and shall index and cross-index the affidavit in the names of the claimant, the original contractor, and the owner. Failure of the county clerk to properly record or index a filed affidavit does not invalidate the lien.