PodToBUILD icon indicating copy to clipboard operation
PodToBUILD copied to clipboard

new_pod_repository with tags fails

Open SwapnilNighot opened this issue 3 years ago • 5 comments

Hi, I am trying to use the new_pod_repository with the tag in the pods URL as below

new_pod_repository(
  name = "SDWebImage",
  url = "https://github.com/SDWebImage/SDWebImage/archive/refs/tags/5.12.3.zip",
  generate_header_map = 1
)

it's failing with the error as below.

Updating Pod SDWebImage...
_exec failed 4  RepoToolsCore/RepoActions.swift:257: Fatal error: Missing podspec ( ./SDWebImage.podspec ) inside /MY_PROJECT_PATH/Vendor/SDWebImage

Also it creates the additional folder with the tag name (Vendor/SDWebImage/SDWebImage-5.12.3). I thought may be it's failing because of it and tried putting podspec_url but it's still failing.

Where as, if I use it without the tag as below

new_pod_repository(
  name = "SDWebImage",
  url = "https://github.com/SDWebImage/SDWebImage/archive/5.12.3.zip",
  generate_header_map = 1
)

Is working as expected.

Is this behaviour is as expected ?

SwapnilNighot avatar Feb 23 '22 16:02 SwapnilNighot

same issue. Bazel can't read generate_header_map property. I don't know why.

lexuanquynh avatar Apr 02 '22 05:04 lexuanquynh

Did you finally have a solution?

Jacky-LinPeng avatar Jul 02 '22 05:07 Jacky-LinPeng

Like I mentioned in the ticket, I am able to consume the pod by using the url without tags. Like this - url = "https://github.com/SDWebImage/SDWebImage/archive/5.12.3.zip"

SwapnilNighot avatar Jul 04 '22 06:07 SwapnilNighot

Like I mentioned in the ticket, I am able to consume the pod by using the url without tags. Like this - url = "https://github.com/SDWebImage/SDWebImage/archive/5.12.3.zip"

After downloading SDWebImage dependencies using new_pod_repository, how do you integrate them into your demo project? I encountered a problem when I imported the "sdwebimage.h" project saying the header file did not exist

Jacky-LinPeng avatar Jul 04 '22 06:07 Jacky-LinPeng

try looking at full path where it falls out - then hard code like this podspec_url = "Vendor/Texture/Texture-3.1.0/Texture.podspec",

johndpope avatar Aug 27 '22 07:08 johndpope