Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Missing newline at end of control file causes error #733

Closed
0xallie opened this issue Apr 29, 2023 · 1 comment · Fixed by #741
Closed

[Bug]: Missing newline at end of control file causes error #733

0xallie opened this issue Apr 29, 2023 · 1 comment · Fixed by #741

Comments

@0xallie
Copy link
Contributor

0xallie commented Apr 29, 2023

What are the steps to reproduce this issue?

  1. Create a control file with no trailing newline (example*)
  2. Do make package

* Note that you have to add Foundation and UIKit imports to Controllers/IPARAccountAndCreditsController.m and Utils/IPARUtils.m for it to compile.

What happens?

ERROR: control file '/Users/alexia/tmp/IPARanger/.theos/_/DEBIAN/control' is missing an Architecture field at /Users/alexia/theos/bin/dm.pl line 84.

The generated control file looks like this:

Package: com.0xkuj.iparanger
Name: IPA Ranger
Description: GUI Based Application for ipatool
Depends: ai.akemi.appsyncunified, gawk, unzip
Maintainer: 0xkuj
Author: 0xkuj
Section: ApplicationsArchitecture: iphoneos-arm
Version: 1.4
Installed-Size: 3356

What were you expecting to happen?

It should handle this situation properly, or at the very least show a more descriptive error message.

Paste any relevant logs, error output, etc.

No response

Additional context

No response

What OS are you seeing the problem on?

macOS

What OS version does it have installed?

13.3.1

What toolchain and version are you using?

Xcode 14.3.0

Which SDK version are you using?

iOS 14.5

What OS is your client device running?

iOS

What OS version does it have installed?

iOS 16.5b2

Which device model is it?

iPhone X

Which jailbreak is it using (if relevant)?

palera1n

@leptos-null
Copy link
Member

noting: Kirb and Lightmann determined this is caused by the line

$(ECHO_NOTHING)sed -e 's/\$${LIBSWIFT}/$(_THEOS_DEB_LIBSWIFT_DEPENDS)/g; s/\$${LIBSWIFT_VERSION}/$(_THEOS_DEB_LIBSWIFT_PACKAGE_VERSION)/g; /^[Vv]ersion:/d; /^[Aa]rchitecture:/d; /^$$/d; $$a\' "$(_THEOS_DEB_PACKAGE_CONTROL_PATH)" > "$@"$(ECHO_END)

because sed always ends with a new line in the GNU build (used on iOS and Linux), but does not on the BSD build (used on macOS).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant