<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>249644</bug_id>
          
          <creation_ts>2022-12-20 05:14:40 -0800</creation_ts>
          <short_desc>[Tools] built-product-archive shouldn&apos;t pass &apos;jsc&apos; as port name for &apos;jsc-only&apos;</short_desc>
          <delta_ts>2022-12-20 10:58:17 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Tools / Tests</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=249604</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>249031</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Carlos Alberto Lopez Perez">clopez</reporter>
          <assigned_to name="Carlos Alberto Lopez Perez">clopez</assigned_to>
          <cc>angelos</cc>
    
    <cc>bugs-noreply</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1920753</commentid>
    <comment_count>0</comment_count>
    <who name="Carlos Alberto Lopez Perez">clopez</who>
    <bug_when>2022-12-20 05:14:40 -0800</bug_when>
    <thetext>When the parameter platform=foo-bar is passed to the script built-product-archive the script picks as platform name &apos;foo&apos;.

This is correct for platform names like ios-wk2 or mac-wk2 where the generic platform name is &apos;mac&apos; or &apos;ios&apos;, but not for &apos;jsc-only&apos;

This may causes issues later when calling the script webkit-build-directory to determine the build directory path.


Example of the issue (with the patch from bug 249604)

OK $ ./Tools/Scripts/webkit-build-directory --release --configuration --cross-target=rpi3-32bits-mesa --jsc-only
/home/clopez/webkit/webkit/WebKitBuild/JSCOnly/Release_rpi3-32bits-mesa


FAIL $ ./Tools/Scripts/webkit-build-directory --release --configuration --cross-target=rpi3-32bits-mesa --jsc
/home/clopez/webkit/webkit/WebKitBuild/Unknown/Release_rpi3-32bits-mesa

It prints &apos;Unknown&apos; as port directory because &apos;jsc&apos; is not a valid port name in webkitdirs.pm so passing --jsc here is like passing any random string

FAIL $ ./Tools/Scripts/webkit-build-directory --release --configuration --cross-target=rpi3-32bits-mesa --magicstring
/home/clopez/webkit/webkit/WebKitBuild/Unknown/Release_rpi3-32bits-mesa


The script webkit-build-directory doesn&apos;t complain when you pass an unknown command line switch, so passing &apos;--jsc&apos; is the same than passing &apos;--magicstring&apos; in this example.

The script build-webkit however complains, and if you pass &apos;--jsc&apos; instead of &apos;--jsc-only&apos; you get:

CMake Error at Source/cmake/WebKitCommon.cmake:57 (message):
  Please choose which WebKit port to build (one of
  AppleWin;Efl;FTW;GTK;JSCOnly;Mac;PlayStation;WPE;WinCairo)
Call Stack (most recent call first):
  CMakeLists.txt:25 (include)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1920755</commentid>
    <comment_count>1</comment_count>
    <who name="Carlos Alberto Lopez Perez">clopez</who>
    <bug_when>2022-12-20 05:26:31 -0800</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/7907</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1920835</commentid>
    <comment_count>2</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2022-12-20 10:57:44 -0800</bug_when>
    <thetext>Committed 258147@main (428d184a46a4): &lt;https://commits.webkit.org/258147@main&gt;

Reviewed commits have been landed. Closing PR #7907 and removing active labels.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1920836</commentid>
    <comment_count>3</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2022-12-20 10:58:17 -0800</bug_when>
    <thetext>&lt;rdar://problem/103563497&gt;</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>