`FAKE_REQUIRED_PACKAGES` tensorflow-intel prevent poetry installation of `tensorflow-rocm`
Hi @ZappaBoy ,

To enable ROCm you have to build from source.

Please find the configuration [here](https://www.tensorflow.org/install/source#expandable-1).

Thank you!! Hi @Varsha-anjanappa,

First of all thanks for your time.
I'm currently using `rocm` successfully. The issue here is about the `FAKE_REQUIRED_PACKAGES` versions definition that prevent to install other `tensorflow` versions different from main versions using package managers like `poetry`.
As you can see the problem is not only related to `tensorflow-rocm` but it's related to all the package with a version longer than the `major.minor.patch` standard versioning. The issue is generated due to the fact that the fake packages like `tensorflow-cpu-aws` and `tensorflow-intel` version follow the `major.minor.patch` standard versioning while other forks can use a `major.minor.patch.other` versioning standard. 

So I think that my proposed solution can be useful but I'm not sure where to place the following line in the `setup.py`:
```python
_VERSION = (".").join(_VERSION.split(".")[:3])
```
Maybe it can be safer to create a `_FAKE_REQUIRED_PACKAGES_VERSION` variable like that:
```python
_FAKE_REQUIRED_PACKAGES_VERSION = (".").join(_VERSION.split(".")[:3])
```
And use `_FAKE_REQUIRED_PACKAGES_VERSION` instead of `_VERSION` in the `FAKE_REQUIRED_PACKAGES` list.
 Hi @Varsha-anjanappa,
I had some free time and I created this PR https://github.com/tensorflow/tensorflow/pull/61444.
I hope this can help to solve the issue. Hi @ZappaBoy ,
Can this issue be closed now ? The PR did not land @Varsha-anjanappa as discussed in the PR this seems to be an issue that the forks of tensorflow will have to solve independently, so this issue can be closed now. Are you satisfied with the resolution of your issue?
<a href="https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61434">Yes</a>
<a href="https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/61434">No</a>

### Issue type

Build/Install

### Have you reproduced the bug with TensorFlow Nightly?

Yes

### Source

source

### TensorFlow version

2.12.0.560

### Custom code

Yes

### OS platform and distribution

Archlinux 6.1.38-2-lts

### Mobile device

_No response_

### Python version

3.11

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

AMD Radeon RX 6700 XT - gfx1031

### Current behavior?

Updating  `tensorflow-rocm` using `poetry` produce a not resolvable dependency error due to `tensorflow-intel` "fake required package". 
The problem is due to the following lines:
https://github.com/tensorflow/tensorflow/blob/6d2f5ac299ef81e3bcd0a431b2375ebbd8252708/tensorflow/tools/pip_package/setup.py#L140-L142
https://github.com/tensorflow/tensorflow/blob/6d2f5ac299ef81e3bcd0a431b2375ebbd8252708/tensorflow/tools/pip_package/setup.py#L143-L144
In particular, the error is caused by the `_VERSION`. In fact, the same version of `tensorflow-rocm` (`2.12.0.560`) not exists in `tensorflow-intel`.


### Standalone code to reproduce the issue

```shell
poetry new fixme
cd fixme
poetry add tensorflow-rocm=="2.12.0.560"
```

### Relevant log output

```shell
Because tensorflow-rocm (2.12.0.560) depends on tensorflow-intel (2.12.0.560) which doesn't match any versions, tensorflow-rocm is forbidden.
So, because lstm-predictor depends on tensorflow-rocm (2.12.0.560), version solving failed.
```


### Possible fix
Simply truncate the version to the patch version before the FAKE_REQUIRED_PACKAGES list definition.
```python
# _VERSION="2.12.0.560"
_VERSION = (".").join(_VERSION.split(".")[:3])
```

### Other open issue
I open the same issue on [ROCmSoftwarePlatform/tensorflow-upstream](https://github.com/ROCmSoftwarePlatform/tensorflow-upstream) [here](https://github.com/ROCmSoftwarePlatform/tensorflow-upstream/issues/2161#issue-1809512685)