After a long period of tense relations, the government of Gen. Wojciech Jaruzelski and the Roman Catholic Church are actively negotiating a range of issues that could shape the church's role in Poland for years to come, church and government officials here say.

The subjects of discussion include the number of new Catholic churches that will be authorized for construction in the next five years, the treatment of opposition activists, a new visit by Pope John Paul II to his homeland and a proposed church aid program for private agriculture. Officials say talks on all these issues have gained momentum in recent weeks, and several are likely to be resolved soon.

For Jaruzelski's government, the move to advance church-state relations forms part of a larger strategy to "normalize" Poland's internal political situation and improve relations with western countries in the face of a coming communist party congress and mounting economic problems.

In pursuit of party support, authorities have signaled a strategy of rolling back some of the church's substantial gains in privileges and political influence since the early 1980s, while avoiding a potentially debilitating confrontation.

At the same time, Jaruzelski appears eager to create at least the appearance of progress on those church-related issues that have been cited by western governments as crucial to the renewal of economic aid to Poland. First among these is the church's longstanding request to establish a foundation for helping Poland's millions of private farmers.

The outcome of these delicately balanced initiatives could have a decisive impact on the future of church-state relations under Jaruzelski's government, church and government sources said. While few observers predict a major improvement in the ties, a failure to find formulas for agreement could undermine seriously Jaruzelski's normalization strategy.

"The government realizes that the only way they are going to create stable conditions for themselves is to come to terms with the church in a way they haven't until now," a diplomat said. "That's clearly what lies behind what is happening now."

One signal of renewed church-government cooperation was the negotiation last month of the dropping of criminal slander charges against Solidarity leader Lech Walesa, church and diplomatic sources said. In intervening to prevent Walesa's trial and possible imprisonment, church authorities obtained what Walesa called "the first step toward a reasonable agreement" between the government and society in several years.

Walesa's case was also one of the few successes in church-government relations since the murder by security forces of an activist priest, the Rev. Jerzy Popieluszko, in October 1984. Since then, negotiations on a number of key issues have been at an impasse.

Despite a meeting last year between Jaruzelski and Cardinal Jozef Glemp, Roman Catholic primate of Poland, the church refused for the first time since the 1950s to support some candidates for the legislature and did not urge Poles to vote in the October elections.

The impulse for the current talks has been created in large part by the government's need to produce programs and political strategy for the next five years in connection with the coming party congress.

Party strategists, in turn, have concluded that curtailing the church's gains since 1980 in construction, the expansion of its influence over cultural activity and its sheltering of the remnants of Solidarity is essential to restoring the party's still-fragile political position.

In a major article in a recent edition an ideological journal addressed to communist activists, Wladyslaw Loranc, the party's chief ideologist, pointed out that the state could not risk an open confrontation with the church without "exposing the interests of Poland's working people to a historic defeat."

However, Loranc said that "we must not tolerate the fact that there is a wall of critical silence being built up around the church. Whenever we encounter displays of [church] power in social terms, such power has to be brought under control, indeed actively resisted in certain situations."

The main manifestation of this strategy has been an effort to halt an unprecedented building boom by the church during the past five years, which Loranc described as "a consequence not only of our own weakness, but also of an atmosphere of relentless pressure and confusion among the general public."

After winning permission during the Solidarity era in 1981 for the construction of nearly 1,000 churches and other buildings, church officials have applied to build 600 more between now and 1990.

Communist authorities, who until 1980 maintained strict limits on church construction, have responded with a political campaign apparently meant to lay the groundwork for rejecting most of the church's request. A major article prepared by officials of the government's Office of Religious Affairs and published in the state-controlled weekly Polityka argued that Poland needed no more churches.

Some neighborhood organizations of the communist-controlled Patriotic Movement for National Revival recently have held "citizens' meetings" with shows of opposition to local building proposals.

Church officials, who have responded with articles in the Catholic press, say that negotiations on the issue, scheduled for completion this month, have been difficult.

"We are just before the party congress, and the authorities seem to want to use this issue to prove their ideological position," one source knowledgeable about the talks said.

On another key issue, authorities have agreed in principle to a third visit by John Paul II to Poland in 1987 but are seeking to block a proposed trip by the pope to Gdansk, the birthplace of Solidarity and home of Walesa, church sources said. Government officials want to control the outpouring of popular feeling that the pope's visits stir in Poland.

At the same time, the government has indicated that it may be prepared to make concessions on the church's proposed program for private agriculture, which has been stalled in negotiations for four years. Church officials say they believe the move has been prompted by pressure from western governments, such as the United States and West Germany, who have linked approval of the fund to the resumption of credits that Poland badly needs to manage its $29 billion foreign debt.

A church source said that in recent weeks, high-ranking government officials have told Polish bishops in two separate, informal contacts that "the political decision to accept the fund has been made." Government spokesman Jerzy Urban announced last week that "the stance of the church favors the development of talks."

In an effort to speed the accord, church officials recently agreed not to accept Walesa's donation to the fund of the $200,000 he received for the 1983 Nobel Peace Prize. In all, the church has raised $34 million for the project, in part through donations from western governments.

Church officials said the government now is pressing for further concessions, such as the removal of several members of the church committee charged with organizing the fund. Catholic leaders are also wary of the government assurances, offered several times in the past but never acted on.

Nevertheless, church leaders and diplomats say the development of negotiations on the foundation may emerge as a key test of Jaruzelski's political course this year.